Файл: public_html/modules/alliance/list.php
Строк: 28
<?php
$root = $_SERVER['DOCUMENT_ROOT'];
include_once ($root.'/core/base.php');
falseauth();
$header = "Альянсы";
include_once ($root.'/core/head.php');
$count = $db -> query("SELECT * FROM `alliances`") -> num_rows;
$k_page = k_page($count,10);
$page = page($k_page);
$start = 10*$page-10;
$sql = $db -> query("SELECT * FROM `alliances` ORDER BY `level` DESC, `exp` DESC, `addtime` DESC LIMIT $start, 10");
while($q = $sql->fetch_object())
{
echo '<div class = "notice_container"><div class = "gborder notice_alert2 alert-success">
<a href="/alliance/info/'.$q->id.'"><img src="/images/users.png" width="35px"> '.$q->name.' '.$q->level.' ур.</a></div></div>';
}
if($count == 0) echo '<div class="b">Ещё не создано альянсов</div>';
if($count >= 10) echo str('/alliance/list/?', $k_page, $page);
echo"<div class = 'line'></div><center><a href = '/rating' class = 'link'>Назад</a></center>";
include_once ($root.'/core/foot.php');