Remove globals
This commit is contained in:
parent
be5779ff27
commit
3b4bbf3a6a
@ -583,6 +583,10 @@ class User
|
||||
|
||||
private function __construct()
|
||||
{
|
||||
if (empty($_SESSION['uid']) && empty($_COOKIE['login'])) {
|
||||
return;
|
||||
}
|
||||
|
||||
$user = !empty($_SESSION['uid']) ? $_SESSION['uid'] : $_COOKIE['login'];
|
||||
$this->info = self::getInfo($user);
|
||||
unset($user);
|
||||
@ -2000,7 +2004,7 @@ class User
|
||||
[$id]
|
||||
);
|
||||
}
|
||||
$r = '';
|
||||
|
||||
if (
|
||||
isset($inf['id']) &&
|
||||
(
|
||||
@ -5544,7 +5548,7 @@ FROM `items_users` AS `iu` LEFT JOIN `items_main` AS `im` ON (`im`.`id` = `iu`.`
|
||||
if (!isset($po['nodelete'])) {
|
||||
$is1 .= ' <a onClick="top.drop(' . $pl['id'] . ',\'' . $pl['img'] . '\',\'' . $pl['name'] . '\',1,\'<table border=\\\'0\\\' width=\\\'100%\\\' cellspacing=\\\'0\\\' cellpadding=\\\'5\\\'><tr><td rowspan=2><img src=\\\'' . Config::img() . '/i/items/' . $pl['img'] . '\\\'></td><td align=\\\'left\\\'>Предмет <strong>' . $pl['name'] . '</strong> будет утерян, вы уверены ?</td></tr></table>\',\'' . intval(
|
||||
$_GET['otdel']
|
||||
) . '\'); return false;" href="javascript:void(0);" title="Выкинуть предмет"><img src="' . Config::img() . '/i/clear.gif"></a>';
|
||||
) . ' . Config::img() . ' / i / clear . gif"></a>';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -953,7 +953,7 @@ from items_users left join items_main on items_main.id = item_id where inOdet !=
|
||||
|
||||
//Бонусы комплектов
|
||||
$i = 0;
|
||||
if (is_array($coms['new'])) {
|
||||
if (!empty($coms['new']) && is_array($coms['new'])) {
|
||||
while ($i <= count($coms['new'])) {
|
||||
if (isset($coms['new'][$i])) {
|
||||
//$coms[$i]['id'] - id комплекта, $j - кол-во предметов данного комплекта
|
||||
|
Loading…
Reference in New Issue
Block a user