Hello i wont to limit torrents.php torrents nun files
i have 2.5Milion torrents and i wont to limit the torrents last 100K on display
UPDATE !
i think i resove the problem from this line torrents.ratingsum / torrents.numratings, by removing it
i have 2.5Milion torrents and i wont to limit the torrents last 100K on display
//Get Total For Pager
$res = mysql_query("SELECT COUNT(*) FROM torrents LEFT JOIN categories ON category = categories.id $where ") or die(mysql_error());
$row = mysql_fetch_array($res);
$count = $row[0];
//get sql info
if ($count) {
list($pagertop, $pagerbottom, $limit) = pager(35, $count, "torrents.php?" . $addparam);
$query = "SELECT torrents.id, torrents.category, torrents.sticky, torrents.recommendedx, torrents.viptorrents, torrents.rosubbed, torrents.hardcoded, torrents.italiansub, torrents.dublatro, torrents.dubbed, torrents.multilang, torrents.multilang, torrents.remux, torrents.HDR, torrents.3d, torrents.flacdst, torrents.adson, torrents.VR, torrents.frenchsub, torrents.russiansub, torrents.engsub, torrents.germansub, torrents.4khdr, torrents.UHD, torrents.fhd,torrents.SD, torrents.KoreanHC, torrents.description, torrents.leechers, torrents.seeders, torrents.name, torrents.size, torrents.added, torrents.torrentlang, torrents.owner, categories.name AS cat_name, torrentlang.name AS lang_name, torrentlang.image AS lang_image, categories.parent_cat AS cat_parent, categories.image AS cat_pic, users.username, users.privacy, IF(torrents.numratings < 2, NULL, ROUND(torrents.ratingsum / torrents.numratings, 1)) AS rating FROM torrents LEFT JOIN categories ON category = categories.id LEFT JOIN torrentlang ON torrents.torrentlang = torrentlang.id LEFT JOIN users ON torrents.owner = users.id $where $orderby $limit";
$res = mysql_query($query) or die(mysql_error());
}else{
unset($res);
}UPDATE !
i think i resove the problem from this line torrents.ratingsum / torrents.numratings, by removing it
Last edited by Extremlym66 on 2023-10-17 07:40:06