File size: 1.89Kb
<?
////////////Автор скрипта: Крупников Антон aka anton65/////////////////Мейл автора: [email protected]/////////Сайт: http://anton65.h2m.ru////////////
Error_Reporting(E_ALL & ~E_NOTICE);
include"config.inc.php";
$date = date("d.m.Y, H:i:s", time());
header("Content-type:text/html;charset=UTF-8");
print'<!HTM_PUBLICATION 4.0><html><head><title>Новости</title><meta http-equiv="Cache-Control" content="no-cache" forua="true"><style type="text/css">
input{background color: '.$fcolor.' ; color: '.$tcolor.' ;}
</style></head><body bgcolor="'.$fcolor.'" text="'.$tcolor.'" link="'.$tcolor.'" alink="'.$tcolor.'" vlink="'.$tcolor.'"><p align="center"><b>'.$date.'</b><br/><big>Новости:</big></p><hr color="'.$tcolor.'">
';
$xfile = @file("text.txt");
$p = "$p";
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=\"index.php?npage=".($npage-1)."\">Назад</a>";
if ($npages > 1 and $npage<$npages)
$gline_next = "<a href=\"index.php?npage=".($npage+1)."\">Вперед</a>";
$line = " | ";
for ($p = 1; $p <= $npages; $p++) {
if ($p != $npage) { $line .= "<a href=\"index.php?npage=$p\"> $p </a>|";}
if ($p == $npage) { $line .= "$p |"; }
}
for ($i = $first-1; $i >= $second-1; $i--) {
$ii = $i;
$ii++;
$udata = explode(":ll:",$xfile[$i]);
print "<small><b>$udata[0]</b></small><br/><small>$udata[1]</small><br/><br/>";
}
print "<hr color=\"'.$tcolor.'\"><a href=\"admin.php\"><b><small>Админ панель</small></b></a><br/>";
print "<a href=\"$mainp\"><b><small>На главную</small></b></a><br/></body></html>";
?>