Файл: colxoz.ru/boss/index.php
Строк: 56
<?
include_once '../system/common.php';
include_once '../system/functions.php';
include_once '../system/user.php';
include_once '../system/h.php';
if(!$user) {
header('location: /');
exit;
}
if($user[level] < 5){
echo "<center><div class='content'><img src='/images/town/hellworld.png'></center>";
echo "<div class='h'>Для сражений с боссами требуется <img src='/images/icon/level.png'> 5 уровень<br>";
echo "Ваш уровень: <img src='/images/icon/level.png'> $user[level]</div>";
echo "</center>";
echo "</div>";
}
if($user[level] >= 5){
$kount = mysql_result(mysql_query("SELECT COUNT(*) FROM `boss`"),0);
echo "<div class='content'><center><img src='/images/town/hellworld.png'></center></div>";
echo "<div class='line'></div>";
if($kount == 0)echo "<div class='content'>Уровень мал для сражений!</div><div class='mini-line'></div>";
$q = mysql_query("SELECT * FROM `boss` ORDER BY `lvl` ASC");
while($boss = mysql_fetch_assoc($q)) {
echo "<div style='display:inline-block;white-space:nowrap;text-align:left;'>";
echo "<span class='yellow'> $boss[name]</span><br><img src='/images/icon/level.png'> $boss[lvl] Уровень<br><img src='/images/icon/gold.png'> $boss[gold], <img src='/images/icon/exp.png'> $boss[exp]";
echo "</div>";
echo "<div class='content'>";
echo "<a class='button' href='boss.php?id=$boss[id]'>Выбрать</a>";
echo "</div>";
echo "<div class='line'></div>";
}
}
include_once '../system/f.php';
?>