Просмотр файла chat/guest.php

Размер файла: 1.55Kb
<?

header("Content-type:text/vnd.wap.wml;charset=utf-8");
print "<?xml version=\"1.0\"?>
<!DOCTYPE wml PUBLIC \"-//WAPFORUM//DTD WML 1.2//EN\" \"http://www.wapforum.org/DTD/wml12.dtd\">
<wml>
<card id=\"tes\" title=\"&#x0413;&#x043E;&#x0441;&#x0442;&#x0435;&#x0432;&#x043E;&#x0439; &#x0440;&#x0435;&#x0436;&#x0438;&#x043C;\">";

$rea = "U2NyaXB0cw==";
$admins = base64_decode($rea);

  $xfile = @file("chat.txt");

  $p = 10;

  if ($npage == ""){$npage = "1";}
  $first = count($xfile) - ($p * ($npage - 1));
  $second = count($xfile) - ($p * $npage) + 1;
  if ($second < 1) {$second = 1;}
  $npages = (int)(count($xfile) / $p);
  if ($news_limiter>((int) ($npages*$p))) $npages = $npages+1;
  if ($npage <= $npages and $npage>1) $gline_rew = "<a href=\"guest.php?npage=".($npage-1)."\">&#x041D;&#x0430;&#x0437;&#x0430;&#x0434;</a>";
  if ($npages > 1 and $npage<$npages) $gline_next = "<a href=\"guest.php?npage=".($npage+1)."\">&#x0412;&#x043F;&#x0435;&#x0440;&#x0435;&#x0434;</a>"; 
  $line = " | ";
 
  for ($p = 1; $p <= $npages; $p++) {
   if ($p != $npage) { $line .= "<a href=\"guest.php?npage=$p\"> $p </a>|";}
   if ($p == $npage) { $line .= "$p |"; }
  }

  print $line;

  for ($i = $first-1; $i >= $second-1; $i--) {
   $ii = $i;
   $ii++;
   $udata = explode("::",$xfile[$i]);
   print "<p><b>$udata[0]</b>:<br/>$udata[1]<br/>==".$i."== </p>";
  }

$real_stri = "aHR0cDovL3Ryb2ZpbW92LmNvbS5ydS93YXAv";
$news_cop = base64_decode($real_stri);

  print $gline_rew." :: ".$gline_next." </card>
</wml>";

?>