<?
echo '<div class="phdr">Yangi taronalar</div>';
$cat = intval($_GET['cat']);
$cat_inf = mysql_query("SELECT * FROM `downpath` WHERE `id` = '11' LIMIT 10");
if(mysql_num_rows($cat_inf)){
    $cat_inf = mysql_fetch_assoc($cat_inf);
}else{
    $cat_inf = array('way' => '');
}
$totalfile = mysql_result(mysql_query("SELECT COUNT(*) FROM `downfiles`  WHERE `type` != 1 AND `status` = 1 && `way` LIKE '" . $cat_inf['way'] ."%'"), 0);
if($totalfile > 10000){ $totalfile = 10000; }
$zap = mysql_query("SELECT * FROM `downfiles` WHERE `type` != 1 AND `status` = 1 && `way` LIKE '" . $cat_inf['way'] ."%' ORDER BY `time` DESC LIMIT " . $start . "," . 10);
while ($ok = mysql_fetch_array($zap)) {
    echo ($i % 2) ? '<div class="menu">' : '<div class="menu">';
    ++$i;
        $ok['name'] = str_replace('||||','',$ok['name']); 
  $new = mysql_result(mysql_query("SELECT COUNT(*) FROM `downfiles` WHERE `time` > '" . (time() - 86400) . "' AND `id` = '" . $ok['id'] . "'"), 0); 
echo "<img src='/img/mp3.png' width='16' height='16'> <a href='/download/loadfile.php?down=".$ok['way']."'>".$ok['name']."</a>";
         if($new > 0){ 
 echo " <img src='/images/new1.gif' alt='*' />"; 
 }else{ 
 echo ''; 




 }
  
  echo '</div>';
    }
if ($totalfile > $kmess)
{
     echo '<div class="menu">' . functions::display_pagination('index.php?act=new&amp;cat='.$cat.'&amp;', $start, $totalfile, $kmess) . '';
     echo '</div>';
}
  ?>