Файл: www/video/top.php
Строк: 16
<?php
define('SECURED', true);
include 'ini.php';
include '../config.php';
div('ТОП-100 файлов');
$rid=intval($_GET['rid']);
$num_items=mysql_result(mysql_query("select count(id) from `games_video` where `razd` = '$rid';"),0);
$q=mysql_query("select * from `games_video` where `razd` = '$rid' order by `downloads` desc");
while($game=mysql_fetch_array($q))
{
$n++;
if(is_integer($n/2)){
echo '<div class="msg2">';
}else{
echo '<div class="msg1">';}
$cat=mysql_fetch_array(mysql_query("select * from `categorys_video` where `id`='".$game['cat_id']."';"));
echo '<a href="/video/'.$game['id'].'/">'.$game['name'].'</a><br/>Скачано: '.$game['downloads'].' раз(а)</div>';
}
echo '»<a href="/video/?rid='.$rid.'">Назад</a>';
echo '</div>';
include '../foot.php';
echo '</div>';
?>