Файл: shop/legendary.php
Строк: 50
<?
require_once('../core/index.php');
require_once('../core/func.php');
avt();
$title="Герои";
require_once('../design/head.php');
$count=$db->query("SELECT id FROM `thing` WHERE `lvl`='5'")->rowCount();
if($count==0){echo '<div class="h2">Снаряжение нет.</div>';}
require '../core/pagination.php';
$pagination = new Pagination;
$pagination->sett($count, 10, true);
$res = $db->query("SELECT * FROM `thing` WHERE `lvl`='5' ORDER by `name` ASC " . $pagination->limit());
foreach($res as $thing){
if ($thing['lvl'] == 1){$rcol = '#B0C3D9';}
if ($thing['lvl'] == 2){$rcol = '#5E98D9';}
if ($thing['lvl'] == 3){$rcol = '#4B69FF';}
if ($thing['lvl'] == 4){$rcol = '#8847FF';}
if ($thing['lvl'] == 5){$rcol = '#D32CE6';}
echo '<div class="h1"><table width="100%" cellspacing="0"><tr><td class="h2" align="center" width="25%"><img style="border-radius: 5px; border: 2px solid '.$rcol.';" src=/design/ico/maneken/'.$thing['id'].'.png></td>';
echo '<td class="h2" width="75%" style="font-size: 12px;">'.$thing['name'].'<br/>Сила: '.$thing['str'].'<br/>Цена: '.$thing['gold'].' рубинов<br/>
<a href=/shop/sl?id='.$thing['id'].'>Купить</a>
</td></tr></table></div>';
}
echo "<div class='pg'>";
echo $pagination->get();
echo "</div>";
echo '<div class="h2"><a class="link540" href=/market>Назад</a></div>';
require_once('../design/foot.php');
?>