//$tags="test";
/*
*/
echo $txt;
echo $menu;
require_once('/usr/local/www/describe.ru/www/ssi/video_out.shtml');
require_once('/usr/local/www/describe.ru/www/ssi/foot-dynamic-page.shtml');
endif;
else:
?>
endif;
function localnavigation()
{
$table="describe_ru";
$onpage=$_GET["onpage"];
$field=$_GET["field"];
$section=$_GET["section"];
if(empty($_GET["page"])){
$page = 0;
} else {
if(!is_numeric($_GET["page"])) die("Неправильный формат номера страницы!");
$page = $_GET["page"];
}
//echo $table." ! ".$field." ! ".$section." ! ".$page." ! ".$onpage."!";
$return = null;
$count = mysql_query("SELECT COUNT(*) FROM $table WHERE field='$field' AND section='$section' ORDER BY date_registration") or die(mysql_error());
$count = mysql_fetch_array($count);
$count = $count[0];
$pages = $count/$onpage;
if($page!==0){
$prev = "
<";
} else {
$prev = "<";
}
if($page
>";
} else {
$next = ">";
}
for($i=0;$i<$pages;$i++)
{
if($i==$page){
$return.="[".($i+1)."]";
} else {
$return.="[".($i+1)."]";
}
}
return $prev.$return.$next;
}
?>