So\'ngi maqolalar'; $total = mysql_result(mysql_query('SELECT COUNT(*) FROM `library_texts` WHERE `premod`=1 '), 0); $page = $page >= ceil($total / $kmess) ? ceil($total / $kmess) : $page; $start = $page == 1 ? 0 : ($page - 1) * $kmess; $nav = ($total > $kmess) ? '
' . functions::display_pagination('?do=dir&id=' . $id . '&', $start, $total, $kmess) . '
' : ''; if ($total) { $sql2 = mysql_query("SELECT * FROM `library_texts` WHERE `premod`=1 ORDER BY `id` DESC LIMIT " . $start . "," . $kmess); //echo $nav; while ($row = mysql_fetch_assoc($sql2)) { $catalog = mysql_fetch_assoc(mysql_query("SELECT `id`, `name` FROM `library_cats` WHERE `id` = " . $row['cat_id'] . " LIMIT 1")); echo '
screen
' . functions::checkout($row['name']) . ' (' . functions::display_date($row['time']) . ')
' . functions::checkout(bbcode::notags($row['announce'])) . ' ...
['.$catalog['name'].'] O\'qildi: ' . $row['count_views'] . ' '; echo '
'; } } else { echo ''; } echo $nav; ?>