<?php
//include_once $SERVER['DOCUMENT_ROOT'].'download/functions.php';
echo '<div class="phdr"><b>Yangi Kino va Konsertlar</b></a></div>';
$cat ='4';
$cat_inf = mysql_query("SELECT * FROM `downpath` WHERE `id` = '" . $cat . "' LIMIT 1");
if(mysql_num_rows($cat_inf)){ 
$cat_inf = mysql_fetch_assoc($cat_inf); 
}else{ 
$cat_inf = array('way' => ''); 
} 
$total = mysql_result(mysql_query("SELECT COUNT(*) FROM `downfiles` WHERE `type` != 1 AND `status` = 1 && `way` LIKE '" . $cat_inf['way'] ."%'"), 0); 
$zap = mysql_query("SELECT * FROM downfiles WHERE type != 1 AND status= 1 && way LIKE '" . $cat_inf['way'] ."%' ORDER BY time DESC LIMIT 5");
while ($ok = mysql_fetch_array($zap)) { 

echo '<div class="daviuz">';
echo '<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='/Davlat/playmp3.png' width='18' height='16'> &nbsp;<a href='/download/" . str_replace(' ', '_', $ok['name']) . "_".$ok['id'].".html'>".$ok['name']." </font></a>";

if($ok['count'] > 50){
echo '<img src="Davlat/hit.png">';
}else{
echo '';
}

echo "</div>";
echo "</div>";
}


echo '<div class="daviuz"><a href="/download/index.php?act=new&cat=4"><big>» </big><b>Barchasini ko\'rish...</b></a></div>';

?>