@@ -36,11 +36,10 @@ discard block |
||
36 | 36 | } |
37 | 37 | |
38 | 38 | public static function db_planet_by_vector($vector, $prefix = '', $for_update = false, $fields = '*') { |
39 | - $galaxy = isset($vector[$prefix . 'galaxy']) ? intval($vector[$prefix . 'galaxy']) : 0; |
|
40 | - $system = isset($vector[$prefix . 'system']) ? intval($vector[$prefix . 'system']) : 0; |
|
41 | - $planet = isset($vector[$prefix . 'planet']) ? intval($vector[$prefix . 'planet']) : 0; |
|
42 | - $planet_type = isset($vector[$prefix . 'planet_type']) ? intval($vector[$prefix . 'planet_type']) : |
|
43 | - (isset($vector[$prefix . 'type']) ? intval($vector[$prefix . 'type']) : 0); |
|
39 | + $galaxy = isset($vector[$prefix.'galaxy']) ? intval($vector[$prefix.'galaxy']) : 0; |
|
40 | + $system = isset($vector[$prefix.'system']) ? intval($vector[$prefix.'system']) : 0; |
|
41 | + $planet = isset($vector[$prefix.'planet']) ? intval($vector[$prefix.'planet']) : 0; |
|
42 | + $planet_type = isset($vector[$prefix.'planet_type']) ? intval($vector[$prefix.'planet_type']) : (isset($vector[$prefix.'type']) ? intval($vector[$prefix.'type']) : 0); |
|
44 | 43 | $planet_type = $planet_type == PT_DEBRIS ? PT_PLANET : $planet_type; |
45 | 44 | |
46 | 45 | return DBStaticPlanet::db_planet_by_gspt_safe($galaxy, $system, $planet, $planet_type, $for_update, $fields); |
@@ -61,17 +60,17 @@ discard block |
||
61 | 60 | } |
62 | 61 | |
63 | 62 | public static function db_planet_by_parent($parent_id, $for_update = false, $fields = '*') { |
64 | - if(!($parent_id = idval($parent_id))) { |
|
63 | + if (!($parent_id = idval($parent_id))) { |
|
65 | 64 | return false; |
66 | 65 | } |
67 | 66 | |
68 | 67 | return classSupernova::db_get_record_list(LOC_PLANET, |
69 | - "`parent_planet` = {$parent_id} AND `planet_type` = " . PT_MOON, true); |
|
68 | + "`parent_planet` = {$parent_id} AND `planet_type` = ".PT_MOON, true); |
|
70 | 69 | } |
71 | 70 | |
72 | 71 | public static function db_planet_by_id_and_owner($planet_id, $owner_id, $for_update = false, $fields = '*') { |
73 | 72 | //if(!($planet_id = intval($planet_id)) || !($owner_id = intval($owner_id))) return false; |
74 | - if(!($planet_id = idval($planet_id)) || !($owner_id = idval($owner_id))) { |
|
73 | + if (!($planet_id = idval($planet_id)) || !($owner_id = idval($owner_id))) { |
|
75 | 74 | return false; |
76 | 75 | } |
77 | 76 | |
@@ -82,12 +81,12 @@ discard block |
||
82 | 81 | |
83 | 82 | public static function db_planet_list_moon_other($user_id, $this_moon_id) { |
84 | 83 | // if(!($user_id = intval($user_id)) || !($this_moon_id = intval($this_moon_id))) return false; |
85 | - if(!($user_id = idval($user_id)) || !($this_moon_id = idval($this_moon_id))) { |
|
84 | + if (!($user_id = idval($user_id)) || !($this_moon_id = idval($this_moon_id))) { |
|
86 | 85 | return false; |
87 | 86 | } |
88 | 87 | |
89 | 88 | return classSupernova::db_get_record_list(LOC_PLANET, |
90 | - "`planet_type` = " . PT_MOON . " AND `id_owner` = {$user_id} AND `id` != {$this_moon_id}"); |
|
89 | + "`planet_type` = ".PT_MOON." AND `id_owner` = {$user_id} AND `id` != {$this_moon_id}"); |
|
91 | 90 | } |
92 | 91 | |
93 | 92 | public static function db_planet_list_in_system($galaxy, $system) { |
@@ -99,7 +98,7 @@ discard block |
||
99 | 98 | } |
100 | 99 | |
101 | 100 | public static function db_planet_list_sorted($user_row, $skip_planet_id = false, $field_list = '', $conditions = '') { |
102 | - if(!is_array($user_row)) { |
|
101 | + if (!is_array($user_row)) { |
|
103 | 102 | return false; |
104 | 103 | } |
105 | 104 | // $field_list = $field_list != '*' ? "{{planets}}.`id`, `name`, `image`, {{planets}}.`galaxy`, {{planets}}.`system`, {{planets}}.`planet`, `planet_type`{$field_list}" : $field_list; |
@@ -113,7 +112,7 @@ discard block |
||
113 | 112 | ); |
114 | 113 | $order_by = classSupernova::$user_options[PLAYER_OPTION_PLANET_SORT]; |
115 | 114 | empty($sort_orders[$order_by]) ? $order_by = SORT_ID : false; |
116 | - $order_by = $sort_orders[$order_by] . ' ' . (classSupernova::$user_options[PLAYER_OPTION_PLANET_SORT_INVERSE] == SORT_ASCENDING ? 'ASC' : 'DESC'); |
|
115 | + $order_by = $sort_orders[$order_by].' '.(classSupernova::$user_options[PLAYER_OPTION_PLANET_SORT_INVERSE] == SORT_ASCENDING ? 'ASC' : 'DESC'); |
|
117 | 116 | |
118 | 117 | // Compilating query |
119 | 118 | return classSupernova::db_get_record_list(LOC_PLANET, |
@@ -121,7 +120,7 @@ discard block |
||
121 | 120 | } |
122 | 121 | |
123 | 122 | public static function db_planet_list_by_user_or_planet($user_id, $planet_id) { |
124 | - if(!($user_id = idval($user_id)) && !($planet_id = idval($planet_id))) { |
|
123 | + if (!($user_id = idval($user_id)) && !($planet_id = idval($planet_id))) { |
|
125 | 124 | return false; |
126 | 125 | } |
127 | 126 | |
@@ -131,7 +130,7 @@ discard block |
||
131 | 130 | |
132 | 131 | public static function db_planet_set_by_id($planet_id, $set) { |
133 | 132 | // if(!($planet_id = intval($planet_id))) return false; |
134 | - if(!($planet_id = idval($planet_id))) { |
|
133 | + if (!($planet_id = idval($planet_id))) { |
|
135 | 134 | return false; |
136 | 135 | } |
137 | 136 | |
@@ -139,7 +138,7 @@ discard block |
||
139 | 138 | } |
140 | 139 | |
141 | 140 | public static function db_planet_set_by_gspt($ui_galaxy, $ui_system, $ui_planet, $ui_planet_type = PT_ALL, $set) { |
142 | - if(!($set = trim($set))) { |
|
141 | + if (!($set = trim($set))) { |
|
143 | 142 | return false; |
144 | 143 | } |
145 | 144 | |
@@ -153,7 +152,7 @@ discard block |
||
153 | 152 | |
154 | 153 | public static function db_planet_set_by_parent($ui_parent_id, $ss_set) { |
155 | 154 | //if(!($si_parent_id = intval($ui_parent_id)) || !($ss_set = trim($ss_set))) return false; |
156 | - if(!($si_parent_id = idval($ui_parent_id)) || !($ss_set = trim($ss_set))) { |
|
155 | + if (!($si_parent_id = idval($ui_parent_id)) || !($ss_set = trim($ss_set))) { |
|
157 | 156 | return false; |
158 | 157 | } |
159 | 158 | |
@@ -162,7 +161,7 @@ discard block |
||
162 | 161 | |
163 | 162 | public static function db_planet_set_by_owner($ui_owner_id, $ss_set) { |
164 | 163 | //if(!($si_owner_id = intval($ui_owner_id)) || !($ss_set = trim($ss_set))) return false; |
165 | - if(!($si_owner_id = idval($ui_owner_id)) || !($ss_set = trim($ss_set))) { |
|
164 | + if (!($si_owner_id = idval($ui_owner_id)) || !($ss_set = trim($ss_set))) { |
|
166 | 165 | return false; |
167 | 166 | } |
168 | 167 | |
@@ -172,11 +171,11 @@ discard block |
||
172 | 171 | |
173 | 172 | public static function db_planet_delete_by_id($planet_id) { |
174 | 173 | // if(!($planet_id = intval($planet_id))) return false; |
175 | - if(!($planet_id = idval($planet_id))) { |
|
174 | + if (!($planet_id = idval($planet_id))) { |
|
176 | 175 | return false; |
177 | 176 | } |
178 | 177 | classSupernova::db_del_record_by_id(LOC_PLANET, $planet_id); |
179 | - classSupernova::db_del_record_list(LOC_UNIT, "`unit_location_type` = " . LOC_PLANET . " AND `unit_location_id` = " . $planet_id); |
|
178 | + classSupernova::db_del_record_list(LOC_UNIT, "`unit_location_type` = ".LOC_PLANET." AND `unit_location_id` = ".$planet_id); |
|
180 | 179 | |
181 | 180 | // Очереди очистятся автоматически по FOREIGN KEY |
182 | 181 | return true; |
@@ -184,11 +183,11 @@ discard block |
||
184 | 183 | |
185 | 184 | public static function db_planet_list_delete_by_owner($ui_owner_id) { |
186 | 185 | // if(!($si_owner_id = intval($ui_owner_id))) return false; |
187 | - if(!($si_owner_id = idval($ui_owner_id))) { |
|
186 | + if (!($si_owner_id = idval($ui_owner_id))) { |
|
188 | 187 | return false; |
189 | 188 | } |
190 | 189 | classSupernova::db_del_record_list(LOC_PLANET, "`id_owner` = {$si_owner_id}"); |
191 | - classSupernova::db_del_record_list(LOC_UNIT, "`unit_location_type` = " . LOC_PLANET . " AND `unit_player_id` = " . $si_owner_id); |
|
190 | + classSupernova::db_del_record_list(LOC_UNIT, "`unit_location_type` = ".LOC_PLANET." AND `unit_player_id` = ".$si_owner_id); |
|
192 | 191 | |
193 | 192 | // Очереди очистятся автоматически по FOREIGN KEY |
194 | 193 | return true; |
@@ -12,7 +12,7 @@ discard block |
||
12 | 12 | JOIN {{users}} AS u ON u.id = cp.chat_player_player_id |
13 | 13 | WHERE |
14 | 14 | `chat_player_refresh_last` >= '{$sql_date}' |
15 | - AND (`banaday` IS NULL OR `banaday` <= " . SN_TIME_NOW . ") |
|
15 | + AND (`banaday` IS NULL OR `banaday` <= ".SN_TIME_NOW.") |
|
16 | 16 | {$ally_add} |
17 | 17 | ORDER BY authlevel DESC, `username`"); |
18 | 18 | } |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | `user` = '{$nick}', |
36 | 36 | `ally_id` = '{$ally_id}', |
37 | 37 | `message` = '{$message}', |
38 | - `timestamp` = " . SN_TIME_NOW . ", |
|
38 | + `timestamp` = ".SN_TIME_NOW.", |
|
39 | 39 | `chat_message_sender_name` = '{$chat_message_sender_name}', |
40 | 40 | `chat_message_recipient_id` = {$chat_message_recipient_id}, |
41 | 41 | `chat_message_recipient_name` = '{$chat_message_recipient_name}'" |
@@ -141,7 +141,7 @@ discard block |
||
141 | 141 | * @param $user |
142 | 142 | */ |
143 | 143 | public static function db_chat_player_update($user) { |
144 | - doquery("UPDATE {{chat_player}} SET `chat_player_refresh_last` = " . SN_TIME_NOW . " WHERE `chat_player_player_id` = {$user['id']} LIMIT 1;"); |
|
144 | + doquery("UPDATE {{chat_player}} SET `chat_player_refresh_last` = ".SN_TIME_NOW." WHERE `chat_player_player_id` = {$user['id']} LIMIT 1;"); |
|
145 | 145 | } |
146 | 146 | |
147 | 147 | |
@@ -212,7 +212,7 @@ discard block |
||
212 | 212 | * @param $user |
213 | 213 | */ |
214 | 214 | public static function db_chat_player_update_activity($user) { |
215 | - doquery("UPDATE {{chat_player}} SET `chat_player_activity` = '" . classSupernova::$db->db_escape(SN_TIME_SQL) . "' WHERE `chat_player_player_id` = {$user['id']} LIMIT 1"); |
|
215 | + doquery("UPDATE {{chat_player}} SET `chat_player_activity` = '".classSupernova::$db->db_escape(SN_TIME_SQL)."' WHERE `chat_player_player_id` = {$user['id']} LIMIT 1"); |
|
216 | 216 | } |
217 | 217 | |
218 | 218 | } |
219 | 219 | \ No newline at end of file |
@@ -66,9 +66,9 @@ discard block |
||
66 | 66 | `ally_name` = '{$ally_name}', |
67 | 67 | `ally_tag` = '{$ally_tag}', |
68 | 68 | `ally_owner` = '{$user['id']}', |
69 | - `ally_owner_range` = '" . classLocale::$lang['ali_leaderRank'] . "', |
|
69 | + `ally_owner_range` = '".classLocale::$lang['ali_leaderRank']."', |
|
70 | 70 | `ally_members` = 1, |
71 | - `ranklist` = '" . classLocale::$lang['ali_defaultRankName'] . ",0,0,0,0,0', |
|
71 | + `ranklist` = '" . classLocale::$lang['ali_defaultRankName'].",0,0,0,0,0', |
|
72 | 72 | `ally_register_time`= " . SN_TIME_NOW |
73 | 73 | ); |
74 | 74 | } |
@@ -87,7 +87,7 @@ discard block |
||
87 | 87 | * @param $POST_text |
88 | 88 | */ |
89 | 89 | public static function db_ally_request_insert($user, $id_ally, $POST_text) { |
90 | - doquery("INSERT INTO {{alliance_requests}} SET `id_user` = {$user['id']}, `id_ally`='{$id_ally}', request_text ='{$POST_text}', request_time=" . SN_TIME_NOW . ";"); |
|
90 | + doquery("INSERT INTO {{alliance_requests}} SET `id_user` = {$user['id']}, `id_ally`='{$id_ally}', request_text ='{$POST_text}', request_time=".SN_TIME_NOW.";"); |
|
91 | 91 | } |
92 | 92 | |
93 | 93 | /** |
@@ -137,7 +137,7 @@ discard block |
||
137 | 137 | * @param $ally |
138 | 138 | */ |
139 | 139 | public static function db_ally_update_by_changeset($ally_changeset, $ally) { |
140 | - doquery("UPDATE {{alliance}} SET " . implode(',', $ally_changeset) . " WHERE `id`='{$ally['id']}' LIMIT 1;"); |
|
140 | + doquery("UPDATE {{alliance}} SET ".implode(',', $ally_changeset)." WHERE `id`='{$ally['id']}' LIMIT 1;"); |
|
141 | 141 | } |
142 | 142 | |
143 | 143 | /** |
@@ -248,7 +248,7 @@ discard block |
||
248 | 248 | * @param $d |
249 | 249 | */ |
250 | 250 | public static function db_ally_request_deny($d) { |
251 | - doquery("UPDATE {{alliance_requests}} SET `request_denied` = 1, `request_text` = '" . classLocale::$lang['ali_req_deny_reason'] . "' WHERE `id_user`= {$d} LIMIT 1;"); |
|
251 | + doquery("UPDATE {{alliance_requests}} SET `request_denied` = 1, `request_text` = '".classLocale::$lang['ali_req_deny_reason']."' WHERE `id_user`= {$d} LIMIT 1;"); |
|
252 | 252 | } |
253 | 253 | |
254 | 254 | /** |
@@ -51,16 +51,16 @@ |
||
51 | 51 | */ |
52 | 52 | public static function db_acs_insert($fleetid, $user, $objFleet) { |
53 | 53 | doquery("INSERT INTO {{aks}} SET |
54 | - `name` = '" . db_escape(classLocale::$lang['flt_acs_prefix'] . $fleetid) . "', |
|
55 | - `teilnehmer` = '" . $user['id'] . "', |
|
56 | - `flotten` = '" . $fleetid . "', |
|
57 | - `ankunft` = '" . $objFleet->time_arrive_to_target . "', |
|
58 | - `galaxy` = '" . $objFleet->fleet_end_galaxy . "', |
|
59 | - `system` = '" . $objFleet->fleet_end_system . "', |
|
60 | - `planet` = '" . $objFleet->fleet_end_planet . "', |
|
61 | - `planet_type` = '" . $objFleet->fleet_end_type . "', |
|
62 | - `eingeladen` = '" . $user['id'] . "', |
|
63 | - `fleet_end_time` = '" . $objFleet->time_return_to_source . "'"); |
|
54 | + `name` = '" . db_escape(classLocale::$lang['flt_acs_prefix'].$fleetid)."', |
|
55 | + `teilnehmer` = '" . $user['id']."', |
|
56 | + `flotten` = '" . $fleetid."', |
|
57 | + `ankunft` = '" . $objFleet->time_arrive_to_target."', |
|
58 | + `galaxy` = '" . $objFleet->fleet_end_galaxy."', |
|
59 | + `system` = '" . $objFleet->fleet_end_system."', |
|
60 | + `planet` = '" . $objFleet->fleet_end_planet."', |
|
61 | + `planet_type` = '" . $objFleet->fleet_end_type."', |
|
62 | + `eingeladen` = '" . $user['id']."', |
|
63 | + `fleet_end_time` = '" . $objFleet->time_return_to_source."'"); |
|
64 | 64 | } |
65 | 65 | |
66 | 66 | /** |
@@ -23,7 +23,7 @@ |
||
23 | 23 | * @return array|bool|mysqli_result|null |
24 | 24 | */ |
25 | 25 | public static function db_missile_list_by_arrival() { |
26 | - $iraks = doquery("SELECT * FROM {{iraks}} WHERE `fleet_end_time` <= " . SN_TIME_NOW . " FOR UPDATE;"); |
|
26 | + $iraks = doquery("SELECT * FROM {{iraks}} WHERE `fleet_end_time` <= ".SN_TIME_NOW." FOR UPDATE;"); |
|
27 | 27 | |
28 | 28 | return $iraks; |
29 | 29 | } |
@@ -12,7 +12,7 @@ discard block |
||
12 | 12 | function db_news_insert_set($announce_time, $text, $detail_url, $user) { |
13 | 13 | doquery("INSERT INTO {{announce}} |
14 | 14 | SET `tsTimeStamp` = FROM_UNIXTIME({$announce_time}), `strAnnounce`='{$text}', detail_url = '{$detail_url}', |
15 | - `user_id` = {$user['id']}, `user_name` = '" . db_escape($user['username']) . "'"); |
|
15 | + `user_id` = {$user['id']}, `user_name` = '".db_escape($user['username'])."'"); |
|
16 | 16 | } |
17 | 17 | |
18 | 18 | function db_survey_insert($announce_id, $survey_question, $survey_until) { |
@@ -93,7 +93,7 @@ discard block |
||
93 | 93 | LEFT JOIN {{survey}} AS s ON s.survey_announce_id = a.idAnnounce |
94 | 94 | LEFT JOIN {{users}} AS u ON u.id = a.user_id |
95 | 95 | {$query_where} |
96 | - ORDER BY `tsTimeStamp` DESC, idAnnounce" . |
|
96 | + ORDER BY `tsTimeStamp` DESC, idAnnounce". |
|
97 | 97 | ($query_limit ? " LIMIT {$query_limit}" : '')); |
98 | 98 | |
99 | 99 | $template->assign_var('NEWS_COUNT', db_num_rows($announce_list)); |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | * @param $note_id_edit |
37 | 37 | */ |
38 | 38 | public static function db_note_update_by_id($note_priority, $note_title, $note_text, $note_galaxy, $note_system, $note_planet, $note_planet_type, $note_sticky, $note_id_edit) { |
39 | - doquery("UPDATE {{notes}} SET `time` = " . SN_TIME_NOW . ", `priority` = {$note_priority}, `title` = '{$note_title}', `text` = '{$note_text}', |
|
39 | + doquery("UPDATE {{notes}} SET `time` = ".SN_TIME_NOW.", `priority` = {$note_priority}, `title` = '{$note_title}', `text` = '{$note_text}', |
|
40 | 40 | `galaxy` = {$note_galaxy}, `system` = {$note_system}, `planet` = {$note_planet}, `planet_type` = {$note_planet_type}, `sticky` = {$note_sticky} |
41 | 41 | WHERE `id` = {$note_id_edit} LIMIT 1;"); |
42 | 42 | } |
@@ -53,7 +53,7 @@ discard block |
||
53 | 53 | * @param $note_sticky |
54 | 54 | */ |
55 | 55 | public static function db_note_insert($user, $note_priority, $note_title, $note_text, $note_galaxy, $note_system, $note_planet, $note_planet_type, $note_sticky) { |
56 | - doquery("INSERT INTO {{notes}} SET `owner` = {$user['id']}, `time` = " . SN_TIME_NOW . ", `priority` = {$note_priority}, `title` = '{$note_title}', `text` = '{$note_text}', |
|
56 | + doquery("INSERT INTO {{notes}} SET `owner` = {$user['id']}, `time` = ".SN_TIME_NOW.", `priority` = {$note_priority}, `title` = '{$note_title}', `text` = '{$note_text}', |
|
57 | 57 | `galaxy` = {$note_galaxy}, `system` = {$note_system}, `planet` = {$note_planet}, `planet_type` = {$note_planet_type}, `sticky` = {$note_sticky};"); |
58 | 58 | } |
59 | 59 |
@@ -19,15 +19,11 @@ discard block |
||
19 | 19 | // ------------------------------------------------------------------ |
20 | 20 | function flt_flyingFleetsSort($a, $b) { |
21 | 21 | // Сравниваем время флотов - кто раньше, тот и первый обрабатывается |
22 | - return $a['fleet_time'] > $b['fleet_time'] ? 1 : ($a['fleet_time'] < $b['fleet_time'] ? -1 : |
|
23 | - // Если время - одинаковое, сравниваем события флотов |
|
22 | + return $a['fleet_time'] > $b['fleet_time'] ? 1 : ($a['fleet_time'] < $b['fleet_time'] ? -1 : // Если время - одинаковое, сравниваем события флотов |
|
24 | 23 | // Если события - одинаковые, то флоты равны |
25 | - ($a['fleet_event'] == $b['fleet_event'] ? 0 : |
|
26 | - // Если события разные - первыми считаем прибывающие флоты |
|
27 | - ($a['fleet_event'] == EVENT_FLT_ARRIVE ? 1 : ($b['fleet_event'] == EVENT_FLT_ARRIVE ? -1 : |
|
28 | - // Если нет прибывающих флотов - дальше считаем флоты, которые закончили миссию |
|
29 | - ($a['fleet_event'] == EVENT_FLT_ACOMPLISH ? 1 : ($b['fleet_event'] == EVENT_FLT_ACOMPLISH ? -1 : |
|
30 | - // Если нет флотов, закончивших задание - остались возвращающиеся флоты, которые равны между собой |
|
24 | + ($a['fleet_event'] == $b['fleet_event'] ? 0 : // Если события разные - первыми считаем прибывающие флоты |
|
25 | + ($a['fleet_event'] == EVENT_FLT_ARRIVE ? 1 : ($b['fleet_event'] == EVENT_FLT_ARRIVE ? -1 : // Если нет прибывающих флотов - дальше считаем флоты, которые закончили миссию |
|
26 | + ($a['fleet_event'] == EVENT_FLT_ACOMPLISH ? 1 : ($b['fleet_event'] == EVENT_FLT_ACOMPLISH ? -1 : // Если нет флотов, закончивших задание - остались возвращающиеся флоты, которые равны между собой |
|
31 | 27 | // TODO: Добавить еще проверку по ID флота и/или времени запуска - что бы обсчитывать их в порядке запуска |
32 | 28 | ( |
33 | 29 | 0 // Вообще сюда доходить не должно - будет отсекаться на равенстве событий |
@@ -45,13 +41,13 @@ discard block |
||
45 | 41 | $handler = fopen('event.log', 'a+'); |
46 | 42 | } |
47 | 43 | |
48 | - fwrite($handler, date(FMT_DATE_TIME_SQL, time()) . ' ' . $msg . "\r\n"); |
|
44 | + fwrite($handler, date(FMT_DATE_TIME_SQL, time()).' '.$msg."\r\n"); |
|
49 | 45 | } |
50 | 46 | |
51 | 47 | // ------------------------------------------------------------------ |
52 | 48 | function flt_flying_fleet_handler($skip_fleet_update = false) { |
53 | 49 | if (true) { |
54 | - if(!defined('IN_AJAX')) { |
|
50 | + if (!defined('IN_AJAX')) { |
|
55 | 51 | print('<div style="color: red; font-size: 300%">Fleet handler is disabled</div>'); |
56 | 52 | pdump('Fleet handler is disabled'); |
57 | 53 | } |
@@ -177,7 +173,7 @@ discard block |
||
177 | 173 | MT_EXPLORE => 'flt_mission_explore', |
178 | 174 | ); |
179 | 175 | foreach ($missions_used as $mission_id => $cork) { |
180 | - require_once(SN_ROOT_PHYSICAL . "includes/includes/{$mission_files[$mission_id]}" . DOT_PHP_EX); |
|
176 | + require_once(SN_ROOT_PHYSICAL."includes/includes/{$mission_files[$mission_id]}".DOT_PHP_EX); |
|
181 | 177 | } |
182 | 178 | |
183 | 179 | //log_file('Обработка миссий'); |
@@ -10,7 +10,7 @@ discard block |
||
10 | 10 | define('INSTALL', false); |
11 | 11 | define('IN_ADMIN', true); |
12 | 12 | |
13 | -require('../common.' . substr(strrchr(__FILE__, '.'), 1)); |
|
13 | +require('../common.'.substr(strrchr(__FILE__, '.'), 1)); |
|
14 | 14 | |
15 | 15 | if ($user['authlevel'] < 3) { |
16 | 16 | AdminMessage(classLocale::$lang['adm_err_denied']); |
@@ -111,7 +111,7 @@ discard block |
||
111 | 111 | foreach ($value as $interval_data) { |
112 | 112 | print("<tr>"); |
113 | 113 | print("<td>{$user_id}</td><td>{$user_record['username']}</td><td>{$interval_data[0]}</td><td>{$interval_data[1]}</td><td>{$interval_data[2]}</td>"); |
114 | - print("<td>" . date(FMT_DATE_TIME_SQL, $user_record['onlinetime']) . "</td>"); |
|
114 | + print("<td>".date(FMT_DATE_TIME_SQL, $user_record['onlinetime'])."</td>"); |
|
115 | 115 | print("</tr>"); |
116 | 116 | } |
117 | 117 | } |