diff --git a/system/acp/engine/index.php b/system/acp/engine/index.php index 3413a04..b1f08b2 100644 --- a/system/acp/engine/index.php +++ b/system/acp/engine/index.php @@ -18,7 +18,7 @@ while ($cb = $sql->get($cbs)) { $html->set('mail', $us['mail']); $html->set('money', $cb['money'] . ' ' . $cfg['currency']); $html->set('cashback', ($cb['money'] - ($cb['money'] / 100 * $cfg['part_output_proc'])) . ' ' . $cfg['currency']); - $html->set('type', $cb['purse']{0} == 'R' ? 'WebMoney' : 'Qiwi'); + $html->set('type', $cb['purse'][0] == 'R' ? 'WebMoney' : 'Qiwi'); $html->set('purse', $cb['purse']); $html->set('gateway', empty($cfg['part_gateway']) ? 'mm' : 'auto'); $html->set('date', sys::today($cb['date'])); diff --git a/system/acp/sections/addons/addpl.php b/system/acp/sections/addons/addpl.php index fd1ff10..0bf6c44 100644 --- a/system/acp/sections/addons/addpl.php +++ b/system/acp/sections/addons/addpl.php @@ -180,7 +180,7 @@ if ($go) { foreach ($aPacks as $packs) $spacks .= trim($packs) . ':'; - $spacks = isset($spacks{0}) ? substr($spacks, 0, -1) : ''; + $spacks = isset($spacks[0]) ? substr($spacks, 0, -1) : ''; $aData['packs'] = $spacks == '' ? 'all' : $spacks; @@ -197,7 +197,7 @@ if ($go) { $incoms .= intval($incom) . ':'; } - $incoms = isset($incoms{0}) ? substr($incoms, 0, -1) : ''; + $incoms = isset($incoms[0]) ? substr($incoms, 0, -1) : ''; $aData['incompatible'] = $incoms; @@ -220,7 +220,7 @@ if ($go) { $choice .= ' '; } - $choice = isset($choice{0}) ? substr(trim($choice), 0, -1) : ''; + $choice = isset($choice[0]) ? substr(trim($choice), 0, -1) : ''; $aData['choice'] = $choice; @@ -237,7 +237,7 @@ if ($go) { $requis .= intval($requi) . ':'; } - $requis = isset($requis{0}) ? substr($requis, 0, -1) : ''; + $requis = isset($requis[0]) ? substr($requis, 0, -1) : ''; $aData['required'] = $requis; diff --git a/system/acp/sections/tarifs/add.php b/system/acp/sections/tarifs/add.php index c563e66..80b498b 100644 --- a/system/acp/sections/tarifs/add.php +++ b/system/acp/sections/tarifs/add.php @@ -132,7 +132,7 @@ if ($go) { $ips .= $ip . ':'; } - $ips = isset($ips{0}) ? substr($ips, 0, -1) : ''; + $ips = isset($ips[0]) ? substr($ips, 0, -1) : ''; $aData['ip'] = $ips; @@ -164,7 +164,7 @@ if ($go) { $list .= intval($pid) . ','; } - $list = isset($list{0}) ? substr($list, 0, -1) : ''; + $list = isset($list[0]) ? substr($list, 0, -1) : ''; if ($list == '') continue; @@ -190,7 +190,7 @@ if ($go) { $cores .= intval($core) . ','; } - $cores = isset($cores{0}) ? substr($cores, 0, -1) : ''; + $cores = isset($cores[0]) ? substr($cores, 0, -1) : ''; $aData['core_fix'] = $cores; @@ -207,7 +207,7 @@ if ($go) { $times .= intval($time) . ':'; } - $times = isset($times{0}) ? substr($times, 0, -1) : ''; + $times = isset($times[0]) ? substr($times, 0, -1) : ''; $aData['time'] = $times; @@ -224,7 +224,7 @@ if ($go) { $timexts .= intval($timext) . ':'; } - $timexts = isset($timexts{0}) ? substr($timexts, 0, -1) : ''; + $timexts = isset($timexts[0]) ? substr($timexts, 0, -1) : ''; $aData['timext'] = $timexts; @@ -241,7 +241,7 @@ if ($go) { $sfps .= intval($fps) . ':'; } - $sfps = isset($sfps{0}) ? substr($sfps, 0, -1) : ''; + $sfps = isset($sfps[0]) ? substr($sfps, 0, -1) : ''; $aData['fps'] = $sfps; @@ -258,7 +258,7 @@ if ($go) { $stick .= intval($tick) . ':'; } - $stick = isset($stick{0}) ? substr($stick, 0, -1) : ''; + $stick = isset($stick[0]) ? substr($stick, 0, -1) : ''; $aData['tickrate'] = $stick; @@ -275,7 +275,7 @@ if ($go) { $sram .= intval($ram) . ':'; } - $sram = isset($sram{0}) ? substr($sram, 0, -1) : ''; + $sram = isset($sram[0]) ? substr($sram, 0, -1) : ''; $aData['ram'] = $sram; @@ -292,7 +292,7 @@ if ($go) { $sprice .= $price . ':'; } - $sprice = isset($sprice{0}) ? substr($sprice, 0, -1) : ''; + $sprice = isset($sprice[0]) ? substr($sprice, 0, -1) : ''; $aData['price'] = $sprice; diff --git a/system/acp/sections/tarifs/tarif.php b/system/acp/sections/tarifs/tarif.php index 282b082..62e4e65 100644 --- a/system/acp/sections/tarifs/tarif.php +++ b/system/acp/sections/tarifs/tarif.php @@ -135,7 +135,7 @@ if ($go) { $ips .= $ip . ':'; } - $ips = isset($ips{0}) ? substr($ips, 0, -1) : ''; + $ips = isset($ips[0]) ? substr($ips, 0, -1) : ''; $aData['ip'] = $ips; @@ -167,7 +167,7 @@ if ($go) { $list .= intval($pid) . ','; } - $list = isset($list{0}) ? substr($list, 0, -1) : ''; + $list = isset($list[0]) ? substr($list, 0, -1) : ''; if ($list == '') continue; @@ -193,7 +193,7 @@ if ($go) { $cores .= intval($core) . ','; } - $cores = isset($cores{0}) ? substr($cores, 0, -1) : ''; + $cores = isset($cores[0]) ? substr($cores, 0, -1) : ''; $aData['core_fix'] = $cores; @@ -210,7 +210,7 @@ if ($go) { $times .= intval($time) . ':'; } - $times = isset($times{0}) ? substr($times, 0, -1) : ''; + $times = isset($times[0]) ? substr($times, 0, -1) : ''; $aData['time'] = $times; @@ -227,7 +227,7 @@ if ($go) { $timexts .= intval($timext) . ':'; } - $timexts = isset($timexts{0}) ? substr($timexts, 0, -1) : ''; + $timexts = isset($timexts[0]) ? substr($timexts, 0, -1) : ''; $aData['timext'] = $timexts; @@ -244,7 +244,7 @@ if ($go) { $sfps .= intval($fps) . ':'; } - $sfps = isset($sfps{0}) ? substr($sfps, 0, -1) : ''; + $sfps = isset($sfps[0]) ? substr($sfps, 0, -1) : ''; $aData['fps'] = $sfps; @@ -261,7 +261,7 @@ if ($go) { $stick .= intval($tick) . ':'; } - $stick = isset($stick{0}) ? substr($stick, 0, -1) : ''; + $stick = isset($stick[0]) ? substr($stick, 0, -1) : ''; $aData['tickrate'] = $stick; @@ -278,7 +278,7 @@ if ($go) { $sram .= intval($ram) . ':'; } - $sram = isset($sram{0}) ? substr($sram, 0, -1) : ''; + $sram = isset($sram[0]) ? substr($sram, 0, -1) : ''; $aData['ram'] = $sram; @@ -295,7 +295,7 @@ if ($go) { $sprice .= $price . ':'; } - $sprice = isset($sprice{0}) ? substr($sprice, 0, -1) : ''; + $sprice = isset($sprice[0]) ? substr($sprice, 0, -1) : ''; $aData['price'] = $sprice; @@ -418,7 +418,7 @@ if ($tarif['game'] == 'cssold') { foreach ($aPrice as $price) $sprice .= $price . ':'; - $sprice = isset($sprice{0}) ? substr($sprice, 0, -1) : ''; + $sprice = isset($sprice[0]) ? substr($sprice, 0, -1) : ''; $tarif['price'] = $sprice; } @@ -448,7 +448,7 @@ $aPacks = sys::b64djs($tarif['packs']); foreach ($aPacks as $name => $fullname) $packs .= '"' . $name . '":"' . $fullname . '",'; -$packs = isset($packs{0}) ? substr($packs, 0, -1) : ''; +$packs = isset($packs[0]) ? substr($packs, 0, -1) : ''; $html->set('packs', $packs); @@ -459,7 +459,7 @@ $aPlugins = sys::b64djs($tarif['plugins_install']); foreach ($aPlugins as $pack => $list) $plugins .= '"' . $pack . '":"' . $list . '",'; -$plugins = isset($plugins{0}) ? substr($plugins, 0, -1) : ''; +$plugins = isset($plugins[0]) ? substr($plugins, 0, -1) : ''; $html->set('plugins_install', $plugins); diff --git a/system/library/acpsystem.php b/system/library/acpsystem.php index d61fc61..3a7938d 100644 --- a/system/library/acpsystem.php +++ b/system/library/acpsystem.php @@ -438,7 +438,7 @@ class sys fclose($stack); - return isset($subnetwork{0}) ? $subnetwork : 'не определена'; + return isset($subnetwork[0]) ? $subnetwork : 'не определена'; } public static function uptime_load($time) diff --git a/system/library/ftp.php b/system/library/ftp.php index 8acefc2..3b2e3a5 100644 --- a/system/library/ftp.php +++ b/system/library/ftp.php @@ -114,10 +114,10 @@ class ftp } foreach ($rawlist as $name => $data) { - if ($data['chmod']{0} == 'd') + if ($data['chmod'][0] == 'd') $aDir[$name] = $data; - elseif ($data['chmod']{0} == '-') + elseif ($data['chmod'][0] == '-') $aFile[$name] = $data; } @@ -154,7 +154,7 @@ class ftp $path = $view['path']; - if ($path{0} != '/') $path = '/' . $path; + if ($path[0] != '/') $path = '/' . $path; if ($path != '/') $path = $path . '/'; @@ -379,7 +379,7 @@ class ftp $path = $data['dir']; - if ($path{0} != '/') $path = '/' . $path; + if ($path[0] != '/') $path = '/' . $path; if ($path != '/') $path = $path . '/'; @@ -388,7 +388,7 @@ class ftp $html->set('owner', $info[2]); $html->set('group', $info[3]); - if ($info[0]{0} == 'd') { + if ($info[0][0] == 'd') { $html->unit('folder', 1); $html->unit('file'); $html->set('size', ''); diff --git a/system/library/games/games.php b/system/library/games/games.php index e52ff22..1447f7c 100644 --- a/system/library/games/games.php +++ b/system/library/games/games.php @@ -173,7 +173,7 @@ class games else { $weeks = $week[1] . ',' . $week[2] . ',' . $week[3] . ',' . $week[4] . ',' . $week[5] . ',' . $week[6] . ',' . $week[7]; $weeks = str_replace(array(',0', '0'), '', $weeks); - $week = $weeks{0} == ',' ? substr($weeks, 1) : $weeks; + $week = $weeks[0] == ',' ? substr($weeks, 1) : $weeks; } $cron_task = $time . $week . ' screen -dmS s' . $id . ' bash -c \'cd /var/enginegp && php cron.php ' . $cfg['cron_key'] . ' server_cron ' . $id . ' ' . $cid . '\''; diff --git a/system/library/geo.php b/system/library/geo.php index aa0f82b..927c509 100644 --- a/system/library/geo.php +++ b/system/library/geo.php @@ -255,7 +255,7 @@ class SxGeo foreach ($pack as $p) { list($type, $name) = explode(':', $p); - $type0 = $type{0}; + $type0 = $type[0]; if ($empty) { $unpacked[$name] = $type0 == 'b' || $type0 == 'c' ? '' : 0; @@ -306,7 +306,7 @@ class SxGeo $v = unpack('S', $val); break; case 'm': - $v = unpack('l', $val . (ord($val{2}) >> 7 ? "\xff" : "\0")); + $v = unpack('l', $val . (ord($val[2]) >> 7 ? "\xff" : "\0")); break; case 'M': $v = unpack('L', $val . "\0"); @@ -325,10 +325,10 @@ class SxGeo break; case 'n': - $v = current(unpack('s', $val)) / pow(10, $type{1}); + $v = current(unpack('s', $val)) / pow(10, $type[1]); break; case 'N': - $v = current(unpack('l', $val)) / pow(10, $type{1}); + $v = current(unpack('l', $val)) / pow(10, $type[1]); break; case 'c': diff --git a/system/library/system.php b/system/library/system.php index fc04e54..8b5cfe0 100644 --- a/system/library/system.php +++ b/system/library/system.php @@ -1024,7 +1024,7 @@ class sys fclose($stack); - return isset($subnetwork{0}) ? $subnetwork : 'не определена'; + return isset($subnetwork[0]) ? $subnetwork : 'не определена'; } public static function rep_act($name, $time = 20) @@ -1375,7 +1375,7 @@ class sys foreach ($aTags as $tag) $text .= '' . trim($tag) . ', '; - return isset($text{0}) ? substr($text, 0, -2) : 'отсутствуют'; + return isset($text[0]) ? substr($text, 0, -2) : 'отсутствуют'; } public static function benefitblock($id, $nmch = false) diff --git a/system/sections/help/action/read.php b/system/sections/help/action/read.php index 3648086..c405740 100644 --- a/system/sections/help/action/read.php +++ b/system/sections/help/action/read.php @@ -36,7 +36,7 @@ if ($id) { $read_now .= '#' . $reader . ' (' . $aGroup[$group] . '), '; } - if (isset($read_now{1})) + if (isset($read_now[1])) $read_now = substr($read_now, 0, -2); sys::out($read_now); diff --git a/system/sections/help/action/write.php b/system/sections/help/action/write.php index dbedd61..55f3131 100644 --- a/system/sections/help/action/write.php +++ b/system/sections/help/action/write.php @@ -44,7 +44,7 @@ if ($id) { $write_now .= '#' . $writer . ' (' . $aGroup[$group] . '), '; } - if (isset($write_now{1})) + if (isset($write_now[1])) $write_now = substr($write_now, 0, -2); sys::out($write_now); diff --git a/system/sections/servers/cs/maps.php b/system/sections/servers/cs/maps.php index abfd5af..70d1e71 100644 --- a/system/sections/servers/cs/maps.php +++ b/system/sections/servers/cs/maps.php @@ -52,7 +52,7 @@ if (isset($url['subsection']) and in_array($url['subsection'], $aSub)) { $i = 0; foreach ($aMaps as $index => $map) { - if (!isset($map{3})) + if (!isset($map[3])) continue; $mapjs = str_replace('$', '-_-', $map); diff --git a/system/sections/servers/csgo/maps.php b/system/sections/servers/csgo/maps.php index 6a5ff39..84a8276 100644 --- a/system/sections/servers/csgo/maps.php +++ b/system/sections/servers/csgo/maps.php @@ -51,7 +51,7 @@ if (isset($url['subsection']) and in_array($url['subsection'], $aSub)) { $i = 0; foreach ($aMaps as $index => $map) { - if (!isset($map{3})) + if (!isset($map[3])) continue; $map = str_replace('./', '', $map); diff --git a/system/sections/servers/css/maps.php b/system/sections/servers/css/maps.php index 1b93d25..e3e2268 100644 --- a/system/sections/servers/css/maps.php +++ b/system/sections/servers/css/maps.php @@ -51,7 +51,7 @@ if (isset($url['subsection']) and in_array($url['subsection'], $aSub)) { $i = 0; foreach ($aMaps as $index => $map) { - if (!isset($map{3})) + if (!isset($map[3])) continue; $mapjs = str_replace('$', '-_-', $map); diff --git a/system/sections/servers/cssold/maps.php b/system/sections/servers/cssold/maps.php index 1b93d25..e3e2268 100644 --- a/system/sections/servers/cssold/maps.php +++ b/system/sections/servers/cssold/maps.php @@ -51,7 +51,7 @@ if (isset($url['subsection']) and in_array($url['subsection'], $aSub)) { $i = 0; foreach ($aMaps as $index => $map) { - if (!isset($map{3})) + if (!isset($map[3])) continue; $mapjs = str_replace('$', '-_-', $map); diff --git a/system/sections/servers/filetp.php b/system/sections/servers/filetp.php index a8ac7f7..cc5ecde 100644 --- a/system/sections/servers/filetp.php +++ b/system/sections/servers/filetp.php @@ -92,7 +92,7 @@ else { $bytes = $server['hdd'] * 1048576; - $server['ftp_passwd'] = isset($server['ftp_passwd']{1}) ? $server['ftp_passwd'] : sys::passwd(8); + $server['ftp_passwd'] = isset($server['ftp_passwd'][1]) ? $server['ftp_passwd'] : sys::passwd(8); $qSql = 'DELETE FROM users WHERE username=\'' . $server['uid'] . '\';' . 'DELETE FROM quotalimits WHERE name=\'' . $server['uid'] . '\';' @@ -165,7 +165,7 @@ else { case 'search': $text = isset($_POST['find']) ? sys::first(explode('.', json_decode($_POST['find']))) : sys::out(); - if (!isset($text{2})) + if (!isset($text[2])) sys::out('Для выполнения поиска, необходимо больше данных'); $ftp->search($text, $id); diff --git a/system/sections/user/lk/index.php b/system/sections/user/lk/index.php index f40ab2e..cc7c587 100644 --- a/system/sections/user/lk/index.php +++ b/system/sections/user/lk/index.php @@ -71,7 +71,7 @@ if ($user['patronymic']) $html->unit('patronymic', true); else $html->unit('patr if ($user['name'] || $user['lastname'] || $user['patronymic']) $html->unit('nlp', true); else $html->unit('nlp'); -if (isset($user['wmr']{0}) and in_array($user['wmr']{0}, array('R', 'Z', 'U'))) +if (isset($user['wmr'][0]) and in_array($user['wmr'][0], array('R', 'Z', 'U'))) $html->unit('wmr', true, true); else $html->unit('wmr', false, true);