</title></head>
<?php  
include $abs1."f.php";   //  
?>
<style>
<?php  
include $abs1."plan/css.htm";
?>
</style>
<?php
if (file_exists("../../../../otd/2.txt"))
{echo '<body leftMargin=0 id=bod topMargin=0  style="overflow:hidden;background:silver;">';
echo '<table id=monoz  border=0 style="width:100%;height:100%;
z-index:3;position:absolute;top:0px;left:0px;">
<tr ><td width=30%>&nbsp;</td><td width=30%  valign=center align=center>
<table border=0 width=400 style="background:white" >
<tr><td><IMG height=60 border=0 src="../../../../d~e~f/pas.jpg"></td>
<td  height=30px ><center><b style="color:red" >ATTENTION !'.
'</b> </center> <br>
<ol>
<li> THE ADMINISTRATOR closed the site to carry out work on its reorganization!
<li> The site will be available after completion of work!
<li> For information, contact your ADMINISTRATOR!
<li> Close site
<li> Check back later!
</ol>
</td></tr>
</table>
</td><td width=30%>&nbsp;</td></tr></table></body></html>';
die;
}
?>
<body leftMargin=0 id=bod topMargin=0  style="overflow:hidden;background:silver">

<b style="display:none" id=sname2>
WEBSITE:
<?php
include "plan/name.txt";
?>
</b>
<div id=h style="z-index:1;opacity:0.3;visibility:hidden;height:100%;width:100%;position:absolute;top:0;left:0;background:black;filter:alpha(opacity=30)">&nbsp;&nbsp;&nbsp;</div> 
<div id=ppp style="z-index:1;opacity:0.3;visibility:hidden;height:100%;width:100%;position:absolute;top:0;left:0;background:black;filter:alpha(opacity=30)">&nbsp;&nbsp;&nbsp;</div> 
<table id=kar border=0 width=100% height=100% style="z-index:4;position:absolute;top:0px;left:0px;display:none" ><tbody>
<tr><td width=25%>&nbsp;</td><td valign=top>
<table border=0  bordercolor="orange" style="background:white"    ><tbody>
<tr style="background:silver"><td align=center><b style="color:yellow">VIEW GALLERY</b></td></tr>
<tr><td align=center><div style="height:30;OVERFLOW: auto;"><b id=po style="background:white">Loading, wait ...</b><div></td></tr>
<tr width=100%>
<td align=center valign=center >
<div id=pic_d style="height:10%;OVERFLOW: auto;">   <img id=im onload=pon(this)></div>
</td></tr><tr  style="background:silver"><td  height=50>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<button onclick="a_begin(this)" title="To begin" style="background:silver"><IMG  border=0 src="../../../../d~e~f/pp1.gif"></button>
<button id=pic_n onclick="a_b(this)" title="Back to" style="background:silver"><IMG  border=0 src="../../../../d~e~f/pp2.gif"></button>
<button onclick="a_f(this)" title="Forward" style="background:silver"><IMG  border=0 src="../../../../d~e~f/pp3.gif"></button> 
<button onclick="a_end(this)" title="To end" style="background:silver"><IMG  border=0 src="../../../../d~e~f/pp4.gif"></button>&nbsp;&nbsp;&nbsp;
<button onclick="av(this)" style="background:silver" title="Start viewing slides in automatic mode from the current slide to the last, forward, with viewing for 5 seconds."><IMG  border=0 src="../../../../d~e~f/tables_19.gif"></button>
<button onclick="st(this)" style="background:silver" title="Stop automatic slide show"><IMG  border=0 src="../../../../d~e~f/tables_21.gif"></button>&nbsp;&nbsp;&nbsp;
<button onclick="b(this)" style="background:silver"  title="Close gallery"><IMG   border=0 src="../../../../d~e~f/z.gif"> </button>&nbsp;&nbsp;&nbsp;
<button onclick="a_i(this)" style="background:silver" title="Resize to frame"><IMG  border=0 src="../../../../d~e~f/tables_12.gif"></button>
<b id=p_s></b>&nbsp;<b id=p_s1></b> </td></tr> </tbody></table>&nbsp;</td><td width=25%>&nbsp;</td></tr></tbody></table>
<!--- --->
<!--- ---->
<table id=gii  border=2 style="width:100%;height:100%;display:none;z-index:3;position:absolute;top:0px;left:0px;">
<tr><td   valign=top align=center ><table BORDER=0><tr style="background:#4682b4;color:white">
<td  height=40px >
<center style=color:yellow id=sname33></center>
<b id=giiza style="background:#4682b4;color:white;FONT-SIZE: large;"></b>&#160;&#160;&#160;
<b style="color:yellow">EDITING THE DIARY</b>&nbsp;
<button  onclick=ziie(1)  title="Save edit" style="background:#dcdcdc">SAVE</button>
&#160;&#160;&#160;<button  onclick=zvin3(this,event) style="background:#dcdcdc">ERASE</button>&#160;&#160;&#160;
&#160;&#160;&#160;<button style="" id=buh title="Show tags. Use this mode to edit tags,
if you know the tags, otherwise click TXT" onclick=but2(this) style="background:#dcdcdc">HTML</button>
&#160;<button id=but  onclick="but3(this)" title="Hide tags. Head, tail tags are replaced with ¶¶." style="background:#dcdcdc" >TXT</button>
&#160;&#160;&#160;&#160;<button onclick="utag(1)" title="Undo all tags. \r\n Click TXT and click me! " 
style="background:#dcdcdc">XX</button>
&#160;&#160;<button title="Mark selection with symbols for group decoration" onclick=to_change()>/##/</button>&#160;&#160; <button title="Remove selection characters" style=width:30 onclick=to_change_del("giir")><strike>/##/</strike></button>
&#160;&#160;<button title="Suggestions distance from each other" onclick=by_point("giir")>.</button>


&nbsp;&nbsp;&nbsp;<button title="To begin" onclick=document.getElementById("giir").scrollTop=0 style="background:white">&nbsp;&#8593;&nbsp;</button>&nbsp;&nbsp;
<button style="background:white" onclick=document.getElementById("giir").scrollTop=9999999 title="To end">&nbsp;&#8595;&nbsp;</button>

&#160;&#160;&#160;&#160;<button onclick=ziie(2) title="Close the editing window without saving" style="background:#dcdcdc">&#160;X&#160;</button>
&#160; &#160; <center style="color:white">in TXT mode, select a text fragment or enter selection characters (/ ## /) and click the desired item in the list:&nbsp;
<div onclick="vta(this,event)"  style="WIDTH: 100%;height:20">
<style>.a{background:#dcdcdc;color:#4682b4;TEXT-DECORATION: none;}</style>
<a class=a href=# title="Text in large">&nbsp;&nbsp;A&nbsp;&nbsp;</a>
<a class=a href=# title="Text small">&nbsp;&nbsp;a&nbsp;&nbsp;</a>
<a class=a href=# title="Text in quotation marks">&nbsp;""&nbsp;</a>
<a class=a href=# title="Indented text "> BLOCKQUOTE </a>, &nbsp;
<a class=a href=# title="Text in bold">&nbsp;&nbsp;B&nbsp;&nbsp;</a>
<a class=a href=# title="Bold red text" style=color:red>&nbsp;&nbsp;B&nbsp;&nbsp;</a>
<a class=a href=# title="Bold blue text"style=color:blue>&nbsp;&nbsp;B&nbsp;&nbsp;</a>
<a class=a href=# title="Bottom index">&nbsp;&nbsp;SUB&nbsp;&nbsp;</a>
<a class=a href=# title="Subscript">&nbsp;&nbsp;SUP&nbsp;&nbsp;</a>
<a class=a href=# title="Largest Title">&nbsp;&nbsp;H1&nbsp;&nbsp;</a>
<a class=a href=# title="Header less than H1">&nbsp;&nbsp;H2&nbsp;&nbsp;</a>
<a class=a href=# title="Header less than H2">&nbsp;&nbsp;H3&nbsp;&nbsp;</a>
 <a class=a href=# title="Header less than H3">&nbsp;&nbsp;H4&nbsp;&nbsp;</a>
 <a class=a href=# title="Header less than H4">&nbsp;&nbsp;H5&nbsp;&nbsp;</a>
 <a class=a href=# title="Header less than H5">&nbsp;&nbsp;H6&nbsp;&nbsp;</a>
 <a class=a href=# title="Precript">&nbsp;&nbsp;I&nbsp;&nbsp;</a>
 <a class=a href=# title="Small">&nbsp;SMALL&nbsp;</a>
 <a class=a href=# title=" Strikethrough">&nbsp;STRIKE&nbsp;</a>
 <a class=a href=# title="Underlined">&nbsp;&nbsp;U&nbsp;&nbsp;</a></div>
<center style="background:#4682b4;color:white">in TXT mode select the inserted value by clicking (or typing) and click the insertion point in the text field:
<div onclick="vta2(this,event)"  style="WIDTH: 100%">
<a class=a href=# title="For a list item, click me">&nbsp;&nbsp;LI&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For the line, click me">&nbsp;&nbsp;HR&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For a new line, click me">&nbsp;&nbsp;BR&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For a comma, click me">&nbsp;&nbsp;,&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For semicolon, click me">&nbsp;&nbsp;;&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For a colon, click me">&nbsp;&nbsp;:&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For exclamation click me">&nbsp;&nbsp;!&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For a question click me">&nbsp;&nbsp;?&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For a point, click me">&nbsp;&nbsp;.&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For a new indented line, click me">&nbsp;&nbsp;N&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For the current date and time, click me">&nbsp;date&nbsp;</a>&#160;
<a class=a href=# title="For a numbered list, click me">&nbsp;OL&nbsp;</a>&#160;
<a class=a href=# title="For the bullet list, click me">&nbsp;UL&nbsp;</a>&nbsp;
<a class=a href=# title="For input>, better not use. ">&nbsp;&lt;&nbsp;</a>&nbsp;
<a class=a href=# title="For typing <, better not use .">&nbsp;&gt;&nbsp;</a> <b style="color:white">to insert:</b> <input type="text" style="width:250" id="inn"  title="To insert me click the text input field"  value="">
&#160; &#160; <button title="Clear insert" style="width:30;color:#316290;background:#f5f5dc;" onclick="zvin2(this)" >x</button>
</div></center>
</td></tr><tr><td><textarea  cols=120 id=giir name="htmgi" onclick="getCaretPos2(this)"  value="" > </textarea></td></tr></table> </td></tr></table>
<table id=gip width=100% height=100% border=0 style="width:100%;height:100%;display:none;z-index:3;position:absolute;top:0px;left:0px;">
<tr><td width=10%  title="For tablets, click here to go to the beginning" onclick=window.top.document.getElementById("bod").scrollTop=0    >&nbsp;</td><td   valign=top align=left><div style="background:#4682b4;color:white">
<center id=sname3></center>
<b id=tde style="background:#4682b4;color:white;FONT-SIZE: large"></b>&#160;&#160;&#160;
<b>VIEWING THE DIARY ENTRIES</b>&nbsp;
&#160;&#160;<b id=gip12 title="To remove a tag, click its text">Cancel on click</b> <img   id=cbgip onclick=atip2(this) src=../../../../d~e~f/no.gif>
&#160;&#160;<button title="Click me to save changes!" id=gip10   onclick="gip7(this,event)">Save</button>&nbsp;
&#160;<button title="Open window for printing!"  onclick="gip8(this,event)">P</button>&nbsp;
&nbsp;<button title="To begin" onclick=document.getElementById("gip1").scrollTop=0 style="background:white">&nbsp;&#8593;&nbsp;</button>&nbsp;
<button style="background:white" onclick=document.getElementById("gip1").scrollTop=9999999 title="To end">&nbsp;&#8595;&nbsp;</button>&nbsp;


<button onclick=gip(1) title="Close a window">&nbsp;&nbsp;X&nbsp;&nbsp;</button>
<DIV id=gip1 onclick=gip6(this,event)  style="OVERFLOW: scroll; background:#fffacd;color:black" align=left>&nbsp;</div>
</td><td width=10% title="For tablets, click here to go to the end" onclick=window.top.document.getElementById("bod").scrollTop=window.top.document.getElementById("gip1").offsetHeight>&nbsp;</td></tr></table>
<!--- ---->
<table id=zii  border=0 style="width:100%;height:100%;display:none;z-index:3;position:absolute;top:0px;left:0px;">
<tr><td width=10%>&nbsp;</td><td   valign=top align=center ><table><tr style="background:green;color:white">
<td  height=40px>
<center style="color:yellow" id=sname44></center>
&#160;&#160;<b id=ziiza style="color:white;FONT-SIZE: large;"></b>&#160;&#160;&#160;&#160;
<b style="color:yellow">
EDITING A NOTEBOOK</b>&#160;&#160;&#160;&#160;&#160;&#160;
<button onclick=ziie(3)  style="background:#dcdcdc" title="Save edit">SAVE</button>
&#160;&#160;&#160;<button  onclick=zvin3(this) style="background:#dcdcdc" >ERASE</button>&#160;&#160;&#160;
&#160;&#160;&#160;<button style="" id=buh2 title="Show tags. Use this mode to edit tags,
if you know the tags, otherwise click TXT" onclick=but2(this) style="background:#dcdcdc">HTML</button>
&#160;<button id=but2  onclick="but3(this)" title="Hide tags. Head, tail tags are replaced with ¶¶." style="background:#dcdcdc" >TXT</button>


&#160;&#160;&#160;&#160;<button  onclick="utag(2)" title="Undo all tags. \r\n Click TXT and click me! " style="background:#dcdcdc">XX</button>

&#160;&#160;<button title="Mark selection with symbols for group decoration" onclick=to_change()>/##/</button>&#160;&#160; <button title="Remove selection characters" style=width:30 onclick=to_change_del("ziir")><strike>/##/</strike></button>
&#160;&#160;<button title="Suggestions distance from each other" onclick=by_point("ziir")>.</button>

&nbsp;&nbsp;&nbsp;<button title="To begin" onclick=document.getElementById("ziir").scrollTop=0 style="background:white">&nbsp;&#8593;&nbsp;</button>&nbsp;&nbsp;
<button style="background:white" onclick=document.getElementById("ziir").scrollTop=9999999 title="To end">&nbsp;&#8595;&nbsp;</button>

&#160;&#160;&#160;&#160;<button onclick=ziie(4) title="Close the editing window without saving" style="background:#dcdcdc">&#160;X&#160;</button>
&#160; &#160; <center style="color:white">in TXT mode, select a text fragment and click the desired list item:&nbsp;
<div onclick="vta(this,event)"  style="WIDTH: 100%;height:20">
<style>.a{background:#dcdcdc;color:#4682b4;TEXT-DECORATION: none;}</style>
<a class=a href=# title="Text in large">&nbsp;&nbsp;A&nbsp;&nbsp;</a>
<a class=a href=# title="Text small">&nbsp;&nbsp;a&nbsp;&nbsp;</a>
<a class=a href=# title="Text in quotation marks">&nbsp;""&nbsp;</a>;
<a class=a href=# title="Indented text ">BLOCKQUOTE</a>, &nbsp;
<a class=a href=# title="Text in bold">&nbsp;&nbsp;B&nbsp;&nbsp;</a>
<a class=a href=# title="Bold red text" style=color:red>&nbsp;&nbsp;B&nbsp;&nbsp;</a>
<a class=a href=# title="Bold blue text"style=color:blue>&nbsp;&nbsp;B&nbsp;&nbsp;</a>
<a class=a href=# title="Bottom index">&nbsp;&nbsp;SUB&nbsp;&nbsp;</a>
<a class=a href=# title="Subscript">&nbsp;&nbsp;SUP&nbsp;&nbsp;</a>
<a class=a href=# title="Largest Title">&nbsp;&nbsp;H1&nbsp;&nbsp;</a>
<a class=a href=# title="Header less than H1">&nbsp;&nbsp;H2&nbsp;&nbsp;</a>
<a class=a href=# title="Header less than H2">&nbsp;&nbsp;H3&nbsp;&nbsp;</a>
 <a class=a href=# title="Header less than H3">&nbsp;&nbsp;H4&nbsp;&nbsp;</a>
 <a class=a href=# title="Header less than H4">&nbsp;&nbsp;H5&nbsp;&nbsp;</a>
 <a class=a href=# title="Header less than H5">&nbsp;&nbsp;H6&nbsp;&nbsp;</a>
 <a class=a href=# title="Precript">&nbsp;&nbsp;I&nbsp;&nbsp;</a>
 <a class=a href=# title="Small">&nbsp;SMALL&nbsp;</a>
 <a class=a href=# title=" Strikethrough">&nbsp;STRIKE&nbsp;</a>
 <a class=a href=# title="Underlined">&nbsp;&nbsp;U&nbsp;&nbsp;</a>
</div>
in TXT mode, select the inserted value by clicking (or typing) and click the insertion point in the text field:
<div onclick = "vta2 (this, event)" style = "WIDTH: 100%">
<a class=a href=# title="For a list item, click me">&nbsp;&nbsp;LI&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For the line, click me">&nbsp;&nbsp;HR&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For a new line, click me">&nbsp;&nbsp;BR&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For a comma, click me">&nbsp;&nbsp;,&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For semicolon, click me">&nbsp;&nbsp;;&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For a colon, click me">&nbsp;&nbsp;:&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For exclamation click me">&nbsp;&nbsp;!&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For a question click me">&nbsp;&nbsp;?&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For a point, click me">&nbsp;&nbsp;.&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For a new indented line, click me">&nbsp;&nbsp;N&nbsp;&nbsp;</a>&#160;
<a class=a href=# title="For the current date and time, click me">&nbsp;date&nbsp;</a>&#160;
<a class=a href=# title="For a numbered list, click me">&nbsp;OL&nbsp;</a>&#160;
<a class=a href=# title="For a bulleted list, click me">&nbsp;UL&nbsp;</a>&#160;
<a class=a href=# title="For input>, better not use. ">&nbsp;& lt;&nbsp;</a>&nbsp;
<a class=a href=# title="For typing <, better not use .">&nbsp;&gt;&nbsp;</a>
 <b style = ""> to insert: </b> <input type = "text" style = "width: 250" id = "inn" title = "To insert me, click the text input field" value = "">
&#160;&#160; <button title = "Clear insert"style="width:30;color:#316290;background:#f5f5dc;" onclick="zvin2(this)" >x</button>
</div>
</td></tr><tr><td><textarea cols=120 id=ziir name="htmgi" style="" onclick="getCaretPos2(this)"   value="" >12345</textarea>
</td></tr></table> </td><td width=10%>&nbsp;</td></tr></table>
<table id=zip width=100% height=100% border=0 style="width:100%;height:100%;display:none;z-index:3;position:absolute;top:0px;left:0px;">
<tr><td width=10% title="For tablets, click here to go to the beginning" onclick=window.top.document.getElementById("bod").scrollTop=0>&nbsp;</td><td   valign=top >
<div style="background:green;color:white">
<center id=sname4></center>

<b id=tde2 style="color:yellow;FONT-SIZE: large;">11111</b>&nbsp;&nbsp;&nbsp;<b>VIEWING THE NOTEBOOK</b>
&#160;&#160;&#160;<b id=zip12>Deselect on click</b> <img  id=cbzip onclick=atip2(this) src=../../../../d~e~f/no.gif>
&#160;&#160;&#160;<button title="Click me to save changes!" id=zip10   onclick="gip7(this,event)">Save</button>&nbsp;&nbsp;&nbsp;
&#160;<button title="Open window for printing!"  onclick="gip8(this,event)">&nbsp;P&nbsp;</button>&nbsp;
&nbsp;<button title="To begin" onclick=document.getElementById("zip1").scrollTop=0 style="background:white">&nbsp;&#8593;&nbsp;</button>&nbsp;&nbsp;
<button style="background:white" onclick=document.getElementById("zip1").scrollTop=9999999 title="To end">&nbsp;&#8595;&nbsp;</button>&nbsp;&nbsp;

<button onclick=zip(1) title="Close a window">&nbsp;&nbsp;X&nbsp;&nbsp;</button>
</div><DIV id=zip1 onclick=gip6(this,event) style="OVERFLOW: scroll; background:#fffacd;color:black" align=left>&nbsp;</div>
</td>
<td width=10% title="For tablets, click here to go to the end" onclick=window.top.document.getElementById("bod").scrollTop=window.top.document.getElementById("zip1").offsetHeight >&nbsp;</td></tr></table>

<table id=tab border=1 width=100% height=100% ><tbody>
<!----- ------>
<tr>
<?php
echo '<td id=zagg colspan=3 height=30 style="background:';
include $abs1."plan/pod/vs-b.txt";
echo '" >';
?>
<table  height=100% border=0 width=100%><tbody>
<tr onclick="top1()">
<td align=center >
<?php
echo '<h1  style="color:';
include $abs1."plan/pod/vs-c.txt";
echo ';width:100%">';
$a= trim($_SERVER['PHP_SELF']);
$aa=str_replace('.php','',$a); //
list($w1,$w2,$w3,$w4,$w5,$w6,$w7)=explode("/",$aa);
$w7=str_replace("-card-file","",$w7);
if ($w7=="help")
{
//echo $w7;

}
else
{$w7=rtr(str_replace("_"," ",$w7));}
echo $w7;
echo '<b style="display:none" id=zagvs>'.$w7.'</b>';

?>
</h1>
</td>
<td align=right title="To go to the beginning, click me or the title">
<button onclick=tabtop() style="background:white;color:brown" title="To the window for printing" ><b>&nbsp;P&nbsp;</b></button>
&nbsp;&nbsp;&nbsp;&nbsp;<a href=# class=menu style="width:70px;" onclick="top1()">
<nobr>
<IMG name=1 border=0  src="../../../../d~e~f/arrow-up.gif">&nbsp;&nbsp;To begin</a>

</nobr>
</td></tr></tbody></table>
<?php
if (file_exists('../../../../otd/1251')) 
{$utf8=0;} else {$utf8=1;}     // 
//**********************************************************************************************
if (isset ($_REQUEST['V']) or isset ($_REQUEST['VR']) )   // 
//***********************************************************************************************
{$tf='/tv/'.trim($_REQUEST['file']). '.htm';              // 
$ifg = wu(getcwd ( ).$tf,$utf8);                          // 
if (file_exists($ifg)) 					                  // 
{$ip=trim($_SERVER["REMOTE_ADDR"]);                       // 
$tf1='/tv/'.trim($_REQUEST['file']). '.txt';              // 
$ifg1 = wu(getcwd ( ).$tf1,$utf8);
$rep1="";
if (file_exists($ifg1))
{}
else
{$rw=file_put_contents($ifg1,'/');     // 
}
$sip= trim(file_get_contents($ifg1));  // 
if (strpos(" ".$sip,'/'.$ip.'/')>0)    // 
{$da=false;}
else //  
{$len=2000;                           // 
if (strlen($sip)>$len)                // 
{$sip=substr($sip,0,$len);
}
$rw=file_put_contents($ifg1,'/'.$ip.$sip);     // 
$da=true;
} 
if ($da)
{$l = file($ifg);                              // 
$k=0;  // 
$s=0;  // 
$sk=1;
$arr=array();
foreach ($l as $li => $lin)                   //  
{if (trim($lin)=='<span>' or trim($lin)=='<SPAN>')                    //
 {$arr[++$li]=trim($l[$li]); 
 ++$k; }
//echo htmlspecialchars($l, ENT_QUOTES)."<br>";
}
foreach ($_REQUEST as $i => $z)               //
{if (is_numeric ($i))                         //
{$kk=1;                                       //
$kkt=1;                                       //
foreach ($arr as $ii => $iin)                 //
{if ($kk==4) {$kk=1;++$kkt;}
if ($kkt==$z) 
{if ($kk==1) {$arr[$ii]=$arr[$ii]+1;}         //
}
++$kk;
}}}
// 
// 
$su=0;                                         //
$kk=1;                                         //
foreach ($arr as $ii => $iin)                  //
{if ($kk==4) {$kk=1;}
if ($kk++==1) {$su=$su+$iin;}                  // 
}
if ($su==0)
{$rep1= '<b id=rep style="background:blue;color:yellow;display:none">You haven`t voted! No choice was made.</b>';
}
else
{$kk=1;                                         //
$sp=0;                                          //
foreach ($arr as $ii => $iin)                   //
{if ($kk==4) {$kk=1;}
if ($kk==1)                                     //
{$zn=$iin;
}
if ($kk==2)                                     // %
{$arr[$ii]=round((100/$su)*$zn);
$sp=$sp+$arr[$ii];
if ($sp>100) {$d=$sp-100; if ($arr[$ii]>0) { $arr[$ii]=$arr[$ii]-$d;}}
$kur=$arr[$ii]/2;                               //
}
if ($kk==3)                                     //
{$arr[$ii]=str_repeat("&nbsp;", $kur);
}
++$kk;
}
$w =fopen($ifg, 'w') or exit;                 	//
foreach ($l as $li => $lin)                     //
{if (array_key_exists ( $li,$arr))               // 
{fwrite($w,$arr[$li]."\r\n");
}
else
{fwrite($w,$lin);
}
}
fclose($w);
}}
if ($rep1=="")
{echo '<b id=rep style="background:blue;color:yellow;display:none">Thanks for voting! Your vote has been counted.</b>';
}
else
{echo $rep1;
}}
else
{echo '<b id=rep style="background:blue;color:yellow;display:none">No voting file! Please contact the developer.</b>';
}}
// *************************************************************************
$rep=""; // 
$tf=""; //
$tt=""; //
//*****************************************************
if (isset ($_REQUEST['Q']))   //
//******************************************************
{$rep="1";
echo '<b id=rep style="background:blue;color:yellow;display:none">Your question has been accepted! The answer will be given shortly.</b>';
$tf='/tq/tq.txt';                                       //
$tt1='Questions-Answers';
}
//******************************************************
if (isset ($_REQUEST['C']))   //
//******************************************************
{$rep="2";
echo '<b id=rep style="background:blue;color:yellow;display:none">Your comment has been accepted! It will be inserted into the page after moderation.</b>';
$tf='/tc/tc.txt';                                      //
$tt1='comments';
}
//******************************************************
if (isset ($_REQUEST['G']))    //
//******************************************************
{$rep="4";
echo '<b id=rep style="background:blue;color:yellow;display:none">Your entry has been accepted! It will be published in the guestbook after moderation.</b>';
$tf='/tg/tg.txt';                                       //
$tt1='guest';
}
$pub="-";
//
//*************************************************************
if (isset ($_REQUEST['QN'])) // 
//*************************************************************
{$rep="5";
echo '<b id=rep style="background:blue;color:yellow;display:none">Your question has been published! The answer will be given shortly.</b>';
$tf='/tq/tq.txt';                                         //
$tt1='Questions-Answers';
$pub="+";
}
//*************************************************************
if (isset ($_REQUEST['CN']))  //
//*************************************************************
{$rep="6";
echo '<b id=rep style="background:blue;color:yellow;display:none">Your comment has been published!</b>';
$tf='/tc/tc.txt';                                         //
$tt1='comments';
$pub="+";
}
//*************************************************************
if (isset ($_REQUEST['ON']))  // 
//*************************************************************
{$rep="7";
echo '<b id=rep style="background:blue;color:yellow;display:none">Your ad has been published!</b>';
$tf='/to/to.txt';                                         // 
$tt1=$tt;
$pub="+";
}
//*************************************************************
if (isset ($_REQUEST['GN']))  // 
//*************************************************************
{$rep="8";
echo '<b id=rep style="background:blue;color:yellow;display:none">Your post has been published!</b>';
$tf='/tg/tg.txt';                                          //
$tt1='guest';
$pub="+";
}

if ($rep!="")                                            //
{$fg = wu(getcwd ( ).$tf,$utf8);                         //
if (file_exists($fg))
{$l = file($fg);                                         //
if (isset ($_REQUEST['img']))
{$img=trim($_REQUEST['img']);} else {$img="";}
if ($img=="")
{$img="s1.gif";}
$text=trim(stripslashes ($_REQUEST['text']));                    //
$name=trim(stripslashes ($_REQUEST['name']));                    //
$text=htmlspecialchars($text, ENT_QUOTES,"cp1251");              //
$name=htmlspecialchars($name, ENT_QUOTES,"cp1251");              //
$text=str_replace("\r\n","&nbsp;&nbsp;&nbsp;&nbsp;<br>",$text);  //
$name=str_replace("\r\n","<br>",$name);                          //
$name=str_replace('//'," ",$name);
$text=str_replace('//'," ",$text);
if ($text=="" or $name=="")
{echo '<b id=rep style="background:blue;color:yellow;display:none">Error while typing! </b>';
}
else
{if ($tt1=='Questions-Answers')                                     // 
{$str=$_SERVER["REMOTE_ADDR"].'//'.$img.'//'.$name.'//'.date("d-m-Y").'//'.$text.
'//Moderator//Wait for an answer!//'.$pub."\r\n";}
else
{$str=$_SERVER["REMOTE_ADDR"].'//'.$img.'//'.$name.'//'.date("d-m-Y").'//'.$text.'//'.$pub."\r\n";}
$w =fopen($fg, 'w') or exit;   	//
fwrite($w,$str);    			//
foreach ($l as $li => $lin)     // 
{fwrite($w,$lin);
}
fclose($w);
//*******************************************************************************************************************
if ($pub=="+")  // 
//*******************************************************************************************************************
{if ($tt1=='Questions-Answers')
{$fhtml=wu(getcwd().'/tq/tq.htm',$utf8);  		//
$wh=fopen($fhtml, 'w') or exit; 		    	//
$l = file($fg); 		   					 	//
// 
fwrite($wh,'<h2 style="background:#b0c4de;width:100%" align=center>Questions-Answers</h2><table border=0 width=100%><tbody>');
$ii=1; // 
//
foreach ($l as $li => $lin)        	            //
{if (substr($lin,0,1)!="*")                     //
{
list($ip,$ka,$im,$d,$t,$ab,$ot,$p)=explode("//",$lin);
if (trim($p)=="+")                              //
{$ww='<tr style="background:#e0ffff">
<td width=10px><b>'.$ii++.'</b></td>
<td width=20px><img src="../../../../d~e~f/'.trim($ka).'"></td>'.
'<td width=70px><nobr><b>'.trim($d).'</nobr></b></td>'.
'<td width=80% colspan=2><b>'.trim($im).'</b><b>,&nbsp;QUESTION:</b></td></tr>'.
'<tr><td></td><td colspan=4>'.trim($t).'</td></tr>'.
'<tr ><td></td><td></td><td style="background:#e0ffff" colspan=3><b>'.$ab.'</b><b>,&nbsp;ANSWERS:</b></td></tr>'.
'<tr><td></td><td></td><td colspan=3>'.$ot.'<hr></td></tr>';
fwrite($wh,$ww);
}}}
fwrite($wh,"</tbody></table>");
fclose($wh);  //
}
//******************************
if ($tt1=='comments')
//******************************
{$fhtml=getcwd().'/tc/tc.htm';  	//
$wh=fopen($fhtml, 'w') or exit; 	// 
$l = file($fg); 		   			//
fwrite($wh,'<h2 style="background:#b0c4de;width:100%" align=center>Comments</h2><table border=0 width=100%><tbody>');
$ii=1; // 
// 
foreach ($l as $li => $lin)        	//  
{if (substr($lin,0,1)!="*")         // 
{list($ip,$ka,$im,$d,$t,$p)=explode('//',$l[$li]);
if (trim($p)=="+")                 // 
{$ww='<tr style="background:#f5f5dc;">
<td width=10px><b>'.trim($ii++).'</b></td>
<td width=10px><img src="../../../../d~e~f/'.$ka.'"></td>
<td width=70px><b><nobr>'.$d.'</nobr></b></td>
<td width=85%><b>'.$im. '</b></td></tr><tr><td></td><td colspan=3>'.str_replace('  ','&nbsp;&nbsp;',$t)."</td></tr>";
fwrite($wh,$ww);
}}}
fwrite($wh,"</tbody></table>");
fclose($wh);  //
}
//***************************
if ($tt1=='guest')
{$fhtml=wu(getcwd().'/tg/tg.htm',$utf8);  		// 
$wh=fopen($fhtml, 'w') or exit; 				//
$l = file($fg); 		   					 	// 
fwrite($wh,'<h2 style="background:#b0c4de;width:100%" align=center>Guest book</h2><table border=0 width=100%><tbody>');
$ii=1; // 
// 
foreach ($l as $li => $lin)        	//
{if (substr($lin,0,1)!="*")         //
{list($ip,$ka,$im,$d,$t,$p)=explode("//",$l[$li]);
if (trim($p)=="+")  // 
{$ww='<tr style="background:#e6e6fa;">
<td width=10px><b>'.trim($ii++).'</b></td>
<td width=10px><img src="../../../../d~e~f/'.$ka.'"></td>
<td width=70px><b><nobr>'.$d.'</nobr></b></td>
<td width=85%><b>'.$im. '</b></td></tr><tr><td></td><td colspan=3>'.str_replace('  ','&nbsp;&nbsp;',$t)."</td></tr>";
fwrite($wh,$ww);
}
}}
fwrite($wh,"</tbody></table>");
fclose($wh);  // 
}
//****************************
if ($tt1=='ads')
{
}
}}}
else
{echo "<b id=rep1 style=background:red;color:yellow>File missing".$tf." Place on page ".$tt1." and repeat.</b></center>";
}
}
?>
</td></tr>
<tr><td  valign=top width=100%>
<?php
echo '<DIV id=ta  style="OVERFLOW:auto;background:';
include $abs1."plan/pod/vd-b.txt";
echo ';color:';
include $abs1."plan/pod/vd-c.txt";
echo '" >';
?>