Completed
Branch master (ab4e85)
by SuperNova.WS
06:22
created
flying_fleets.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -2,9 +2,9 @@  discard block
 block discarded – undo
2 2
 
3 3
 include('common.' . substr(strrchr(__FILE__, '.'), 1));
4 4
 
5
-if(!empty($_POST['return']) && is_array($_POST['return'])) {
6
-  foreach($_POST['return'] as $fleet_id) {
7
-    if($fleet_id = idval($fleet_id)) {
5
+if (!empty($_POST['return']) && is_array($_POST['return'])) {
6
+  foreach ($_POST['return'] as $fleet_id) {
7
+    if ($fleet_id = idval($fleet_id)) {
8 8
       sn_db_transaction_start();
9 9
       $FleetRow = doquery("SELECT * FROM {{fleets}} WHERE `fleet_id` = '{$fleet_id}' LIMIT 1 FOR UPDATE;", true);
10 10
 
@@ -12,7 +12,7 @@  discard block
 block discarded – undo
12 12
         $ReturnFlyingTime = ($FleetRow['fleet_end_stay'] != 0 && $FleetRow['fleet_start_time'] < SN_TIME_NOW ? $FleetRow['fleet_start_time'] : SN_TIME_NOW) - $FleetRow['start_time'] + SN_TIME_NOW + 1;
13 13
         doquery("UPDATE {{fleets}} SET `fleet_start_time` = " . SN_TIME_NOW . ", `fleet_group` = 0, `fleet_end_stay` = '0', `fleet_end_time` = '{$ReturnFlyingTime}', `fleet_target_owner` = '{$user['id']}', `fleet_mess` = '1' WHERE `fleet_id` = '{$fleet_id}' LIMIT 1;");
14 14
 
15
-        if($FleetRow['fleet_group']) {
15
+        if ($FleetRow['fleet_group']) {
16 16
           // TODO: Make here to delete only one AKS - by adding aks_fleet_count to AKS table
17 17
           doquery('DELETE FROM {{aks}} WHERE `id` NOT IN (SELECT DISTINCT `fleet_group` FROM {{fleets}});');
18 18
         }
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
 lng_include('overview');
30 30
 lng_include('fleet');
31 31
 
32
-if(!$planetrow) {
32
+if (!$planetrow) {
33 33
   message($lang['fl_noplanetrow'], $lang['fl_error']);
34 34
 }
35 35
 
@@ -44,13 +44,13 @@  discard block
 block discarded – undo
44 44
 
45 45
   $template->assign_block_vars('fleets', $fleet_data['fleet']);
46 46
 
47
-  foreach($fleet_data['ships'] as $ship_data) {
47
+  foreach ($fleet_data['ships'] as $ship_data) {
48 48
     $template->assign_block_vars('fleets.ships', $ship_data);
49 49
   }
50 50
 }
51 51
 
52 52
 $MaxExpeditions = get_player_max_expeditons($user);
53
-if($MaxExpeditions) {
53
+if ($MaxExpeditions) {
54 54
   $FlyingExpeditions  = doquery("SELECT COUNT(fleet_owner) AS `expedi` FROM {{fleets}} WHERE `fleet_owner` = {$user['id']} AND `fleet_mission` = '" . MT_EXPLORE . "';", '', true);
55 55
   $FlyingExpeditions  = $FlyingExpeditions['expedi'];
56 56
 } else {
Please login to merge, or discard this patch.
common.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -12,25 +12,25 @@  discard block
 block discarded – undo
12 12
 global $debug, $sn_mvc, $template_result, $user;
13 13
 
14 14
 // Напоминание для Администрации, что игра отключена
15
-if($template_result[F_GAME_DISABLE]) {
15
+if ($template_result[F_GAME_DISABLE]) {
16 16
   // $disable_reason = sys_bbcodeParse($config->game_disable_reason); // Должна быть инициализирована выше по коду - в init.php
17 17
   echo '<div class="global_admin_warning">', $template_result[F_GAME_DISABLE_REASON], '</div>';
18 18
 }
19 19
 unset($disable_reason);
20 20
 
21 21
 
22
-if(defined('IN_ADMIN') && IN_ADMIN === true) {
22
+if (defined('IN_ADMIN') && IN_ADMIN === true) {
23 23
   lng_include('admin');
24
-} elseif($sys_user_logged_in) {
24
+} elseif ($sys_user_logged_in) {
25 25
   sys_user_vacation($user);
26 26
 
27 27
   $planet_id = SetSelectedPlanet($user);
28 28
 
29 29
   // TODO НЕ НУЖНО АЛЬЯНС КАЖДЫЙ РАЗ ОБНОВЛЯТЬ!!!
30
-  if($user['ally_id']) {
30
+  if ($user['ally_id']) {
31 31
     sn_db_transaction_start();
32 32
     sn_ali_fill_user_ally($user);
33
-    if(!$user['ally']['player']['id']) {
33
+    if (!$user['ally']['player']['id']) {
34 34
       // sn_sys_logout(false, true);
35 35
       // core_auth::logout(false);
36 36
       classSupernova::$auth->logout(false);
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
   sn_db_transaction_commit();
50 50
 
51 51
   $planetrow = $global_data['planet'];
52
-  if(!($planetrow && isset($planetrow['id']) && $planetrow['id'])) {
52
+  if (!($planetrow && isset($planetrow['id']) && $planetrow['id'])) {
53 53
     // sn_sys_logout(false, true);
54 54
     // core_auth::logout(false);
55 55
     classSupernova::$auth->logout(false);
@@ -61,9 +61,9 @@  discard block
 block discarded – undo
61 61
 
62 62
 require_once('includes/vars_menu.php');
63 63
 
64
-if($sn_mvc['model']['']) {
65
-  foreach($sn_mvc['model'][''] as $hook) {
66
-    if(is_callable($hook_call = (is_string($hook) ? $hook : (is_array($hook) ? $hook['callable'] : $hook->callable)))) {
64
+if ($sn_mvc['model']['']) {
65
+  foreach ($sn_mvc['model'][''] as $hook) {
66
+    if (is_callable($hook_call = (is_string($hook) ? $hook : (is_array($hook) ? $hook['callable'] : $hook->callable)))) {
67 67
       call_user_func($hook_call);
68 68
     }
69 69
   }
Please login to merge, or discard this patch.
resources.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -46,11 +46,11 @@  discard block
 block discarded – undo
46 46
   ));
47 47
 };
48 48
 
49
-$ValidList['percent'] = array (  0,  10,  20,  30,  40,  50,  60,  70,  80,  90, 100 );
49
+$ValidList['percent'] = array(0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100);
50 50
 $template = gettemplate('resources', true);
51 51
 
52 52
 $transmutation_result = sn_sys_planet_core_transmute($user, $planetrow);
53
-if(!empty($transmutation_result))
53
+if (!empty($transmutation_result))
54 54
 {
55 55
   $template->assign_block_vars('result', $transmutation_result); // array('STATUS' => $transmutation_result['STATUS'], 'MESSAGE' => $transmutation_result['MESSAGE']));
56 56
 }
@@ -59,20 +59,20 @@  discard block
 block discarded – undo
59 59
 $production = $_POST['production'];
60 60
 //$SubQry     = '';
61 61
 $SubQry     = array();
62
-if(is_array($production)) {
63
-  foreach($production as $prod_id => $percent) {
64
-    if($percent > 100 || $percent < 0) {
62
+if (is_array($production)) {
63
+  foreach ($production as $prod_id => $percent) {
64
+    if ($percent > 100 || $percent < 0) {
65 65
       $debug->warning('Supplying wrong production percent (less then 0 or greater then 100)', 'Hack attempt', 302, array('base_dump' => true));
66 66
       die();
67 67
     }
68 68
 
69 69
     $prod_id = intval($prod_id);
70
-    if(in_array($prod_id, $sn_group_factories) && get_unit_param($prod_id, P_MINING_IS_MANAGED)) {
70
+    if (in_array($prod_id, $sn_group_factories) && get_unit_param($prod_id, P_MINING_IS_MANAGED)) {
71 71
       $field_name              = pname_factory_production_field_name($prod_id);
72 72
       $percent                 = floor($percent / 10);
73 73
       $planetrow[$field_name]  = $percent;
74 74
       //$SubQry                 .= "`{$field_name}` = '{$percent}',";
75
-      $SubQry[]                 = "`{$field_name}` = '{$percent}'";
75
+      $SubQry[] = "`{$field_name}` = '{$percent}'";
76 76
     } else {
77 77
       $debug->warning('Supplying wrong ID in production array - attempt to change some field - ID' . $prod_id, 'Resource Page', 301);
78 78
       continue;
@@ -108,9 +108,9 @@  discard block
 block discarded – undo
108 108
   'ENERGY_TYPE'    => pretty_number($caps_real['production'][RES_ENERGY][0], true, true),
109 109
 ));
110 110
 
111
-foreach($sn_group_factories as $unit_id)
111
+foreach ($sn_group_factories as $unit_id)
112 112
 {
113
-  if(mrc_get_level($user, $planetrow, $unit_id) > 0 && get_unit_param($unit_id))
113
+  if (mrc_get_level($user, $planetrow, $unit_id) > 0 && get_unit_param($unit_id))
114 114
   {
115 115
     $level_plain = mrc_get_level($user, $planetrow, $unit_id, false, true);
116 116
     $template->assign_block_vars('production', array(
Please login to merge, or discard this patch.
admin/adm_user_analyze.php 1 patch
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -12,20 +12,20 @@  discard block
 block discarded – undo
12 12
 
13 13
 require('../common.' . substr(strrchr(__FILE__, '.'), 1));
14 14
 
15
-if($user['authlevel'] < 3) {
15
+if ($user['authlevel'] < 3) {
16 16
   AdminMessage($lang['adm_err_denied']);
17 17
 }
18 18
 
19 19
 // define('SESSION_INTERRUPT', 15*60); // Можно увеличить до 4 часов - никито не может сидеть 2 суток с перерывом менее 4 часов
20 20
 // define('SUSPICIOUS_LONG', 2 * 60*60); // Тогда это увеличиваем до, скажем суток - и там смотрим
21 21
 
22
-define('SESSION_INTERRUPT', 1 * 60*60); // Можно увеличить до 4 часов - никито не может сидеть 2 суток с перерывом менее 4 часов
23
-define('SUSPICIOUS_LONG', 16 * 60*60); // Тогда это увеличиваем до, скажем суток - и там смотрим
22
+define('SESSION_INTERRUPT', 1 * 60 * 60); // Можно увеличить до 4 часов - никито не может сидеть 2 суток с перерывом менее 4 часов
23
+define('SUSPICIOUS_LONG', 16 * 60 * 60); // Тогда это увеличиваем до, скажем суток - и там смотрим
24 24
 
25 25
 
26 26
 function check_suspicious(&$session, &$session_list_last_id, &$row) {
27 27
   $session[2] = $session[1] - $session[0];
28
-  if($session[2] > SUSPICIOUS_LONG)
28
+  if ($session[2] > SUSPICIOUS_LONG)
29 29
   {
30 30
     $session[2] = pretty_time($session[2]);
31 31
     $session[0] = date(FMT_DATE_TIME_SQL, $session[0]);
@@ -46,24 +46,24 @@  discard block
 block discarded – undo
46 46
 $session_list = array();
47 47
 $query = doquery("SELECT `visit_time`, user_id FROM {{counter}} where user_id <> 0 and visit_time > UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 7 DAY)) order by user_id, visit_time;");
48 48
 $session = array();
49
-if($row = db_fetch($query)) {
49
+if ($row = db_fetch($query)) {
50 50
   $session = array(
51 51
     0 => strtotime($row['visit_time']), // start
52 52
     1 => strtotime($row['visit_time']), // end
53 53
   );
54 54
   $last_id = $row['user_id'];
55 55
 }
56
-while($row = db_fetch($query)) {
56
+while ($row = db_fetch($query)) {
57 57
   $row['visit_time'] = strtotime($row['visit_time']);
58
-  if($last_id == $row['user_id']) {
58
+  if ($last_id == $row['user_id']) {
59 59
     // Тот же юзер
60
-    if($row['visit_time'] - $session[1] <= SESSION_INTERRUPT) { // Та же сессия
60
+    if ($row['visit_time'] - $session[1] <= SESSION_INTERRUPT) { // Та же сессия
61 61
       $session[1] = $row['visit_time'];
62 62
     } else {
63 63
       // Новая сессия
64 64
 //      check_suspicious($session, $session_list[$last_id], $row);
65 65
       $session[2] = $session[1] - $session[0];
66
-      if($session[2] > SUSPICIOUS_LONG)
66
+      if ($session[2] > SUSPICIOUS_LONG)
67 67
       {
68 68
         $session[2] = pretty_time($session[2]);
69 69
         $session[0] = date(FMT_DATE_TIME_SQL, $session[0]);
@@ -78,7 +78,7 @@  discard block
 block discarded – undo
78 78
   } else {
79 79
 //    check_suspicious($session, $session_list[$last_id], $row);
80 80
     $session[2] = $session[1] - $session[0];
81
-      if($session[2] > SUSPICIOUS_LONG)
81
+      if ($session[2] > SUSPICIOUS_LONG)
82 82
       {
83 83
         $session[2] = pretty_time($session[2]);
84 84
         $session[0] = date(FMT_DATE_TIME_SQL, $session[0]);
@@ -93,11 +93,11 @@  discard block
 block discarded – undo
93 93
   }
94 94
 }
95 95
 
96
-if($last_id) {
96
+if ($last_id) {
97 97
   // check_suspicious($session, $session_list[$last_id], $row = array('time' => 0));
98 98
   $session[2] = $session[1] - $session[0];
99 99
 
100
-  if($session[2] > SUSPICIOUS_LONG)
100
+  if ($session[2] > SUSPICIOUS_LONG)
101 101
   {
102 102
     $session[2] = pretty_time($session[2]);
103 103
     $session[0] = date(FMT_DATE_TIME_SQL, $session[0]);
@@ -111,9 +111,9 @@  discard block
 block discarded – undo
111 111
 print("<td>ID</td><td>Username</td><td>Start</td><td>End</td><td>Length</td>");
112 112
 print("<td>Last online</td>");
113 113
 print("</tr>");
114
-foreach($session_list as $user_id => $value) {
114
+foreach ($session_list as $user_id => $value) {
115 115
   $user_record = doquery("SELECT `username`, onlinetime FROM {{users}} WHERE id = {$user_id};", true);
116
-  foreach($value as $interval_data) {
116
+  foreach ($value as $interval_data) {
117 117
     print("<tr>");
118 118
     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>");
119 119
     print("<td>" . date(FMT_DATE_TIME_SQL, $user_record['onlinetime']) . "</td>");
Please login to merge, or discard this patch.
admin/banned.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -27,9 +27,9 @@  discard block
 block discarded – undo
27 27
 $action = sys_get_param_str('action');
28 28
 
29 29
 $player_banned_row = db_user_by_username($name_unsafe);
30
-if($mode == 'banit' && $action)
30
+if ($mode == 'banit' && $action)
31 31
 {
32
-  if($player_banned_row)
32
+  if ($player_banned_row)
33 33
   {
34 34
     $reas = $_POST['why'];
35 35
     $days = $_POST['days'];
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
 
49 49
     $DoneMessage = "{$lang['adm_bn_thpl']} {$name_output} {$lang['adm_bn_isbn']}";
50 50
 
51
-    if($is_vacation)
51
+    if ($is_vacation)
52 52
     {
53 53
       $DoneMessage .= $lang['adm_bn_vctn'];
54 54
     }
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
 
63 63
   AdminMessage($DoneMessage, $lang['adm_ban_title']);
64 64
 }
65
-elseif($mode == 'unbanit' && $action)
65
+elseif ($mode == 'unbanit' && $action)
66 66
 {
67 67
   sys_admin_player_ban_unset($user, $player_banned_row, ($reason = sys_get_param_str('why')) ? $reason : $lang['sys_unbanned']);
68 68
 
Please login to merge, or discard this patch.
admin/add_moon.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -14,14 +14,14 @@
 block discarded – undo
14 14
 require('../common.' . substr(strrchr(__FILE__, '.'), 1));
15 15
 
16 16
 // if ($user['authlevel'] < 2)
17
-if($user['authlevel'] < 3)
17
+if ($user['authlevel'] < 3)
18 18
 {
19 19
   AdminMessage($lang['adm_err_denied']);
20 20
 }
21 21
 
22 22
 $template = gettemplate("admin/add_moon", true);
23 23
 
24
-if(sys_get_param_str('mode') == 'addit')
24
+if (sys_get_param_str('mode') == 'addit')
25 25
 {
26 26
   $PlanetID = sys_get_param_id('user');
27 27
   $MoonName = sys_get_param_str('name');
Please login to merge, or discard this patch.
admin/tools.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -6,26 +6,26 @@  discard block
 block discarded – undo
6 6
  * @copyright 2009 by Gorlum for http://oGame.Triolan.COM.UA
7 7
  */
8 8
 
9
-define('INSIDE'  , true);
10
-define('INSTALL' , false);
9
+define('INSIDE', true);
10
+define('INSTALL', false);
11 11
 define('IN_ADMIN', true);
12 12
 require('../common.' . substr(strrchr(__FILE__, '.'), 1));
13 13
 
14 14
 // if($user['authlevel'] < 1)
15
-if($user['authlevel'] < 3)
15
+if ($user['authlevel'] < 3)
16 16
 {
17 17
   AdminMessage($lang['adm_err_denied']);
18 18
 }
19 19
 
20 20
 $mode = sys_get_param_int('mode');
21 21
 
22
-switch($mode){
22
+switch ($mode) {
23 23
   case ADM_TOOL_CONFIG_RELOAD:
24 24
     $config->db_loadAll();
25 25
     sys_refresh_tablelist();
26 26
 
27 27
     $config->db_loadItem('game_watchlist');
28
-    if($config->game_watchlist)
28
+    if ($config->game_watchlist)
29 29
     {
30 30
       $config->game_watchlist_array = explode(';', $config->game_watchlist);
31 31
     }
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
       'STRING' => htmlentities($string),
48 48
       'MD5' => md5($string),
49 49
     ));
50
-    display($template, $lang['adm_tools_md5_header'], false, '', true );
50
+    display($template, $lang['adm_tools_md5_header'], false, '', true);
51 51
   break;
52 52
 
53 53
   case ADM_TOOL_FORCE_ALL:
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
       $lang['adm_tool_sql_client_version'] => db_get_client_info(),
74 74
       $lang['adm_tool_sql_host_info']      => db_get_host_info(),
75 75
     );
76
-    foreach($status as $key => $value)
76
+    foreach ($status as $key => $value)
77 77
     {
78 78
       $template->assign_block_vars('table.row', array(
79 79
         'VALUE_1' => $key,
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
 
84 84
     $template->assign_block_vars('table', $lang['adm_tool_sql_table']['status']);
85 85
     $status = explode('  ', db_server_stat());
86
-    foreach($status as $value)
86
+    foreach ($status as $value)
87 87
     {
88 88
       $row = explode(': ', $value);
89 89
       $template->assign_block_vars('table.row', array(
@@ -95,7 +95,7 @@  discard block
 block discarded – undo
95 95
 
96 96
     $template->assign_block_vars('table', $lang['adm_tool_sql_table']['params']);
97 97
     $result = doquery('SHOW STATUS;');
98
-    while($row = db_fetch($result))
98
+    while ($row = db_fetch($result))
99 99
     {
100 100
       $template->assign_block_vars('table.row', array(
101 101
         'VALUE_1' => $row['Variable_name'],
@@ -110,10 +110,10 @@  discard block
 block discarded – undo
110 110
       'TABLE_FOOTER' => 'test',
111 111
     ));
112 112
 
113
-    display( $template, $lang['adm_bn_ttle'], false, '', true);
113
+    display($template, $lang['adm_bn_ttle'], false, '', true);
114 114
   break;
115 115
 
116 116
 }
117 117
 
118
-display( parsetemplate(gettemplate("admin/admin_tools", true)), $lang['adm_bn_ttle'], false, '', true);
118
+display(parsetemplate(gettemplate("admin/admin_tools", true)), $lang['adm_bn_ttle'], false, '', true);
119 119
 ?>
Please login to merge, or discard this patch.
admin/settings.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -8,18 +8,18 @@  discard block
 block discarded – undo
8 8
  * @copyright 2008 by ??????? for XNova
9 9
  */
10 10
 
11
-define('INSIDE'  , true);
12
-define('INSTALL' , false);
11
+define('INSIDE', true);
12
+define('INSTALL', false);
13 13
 define('IN_ADMIN', true);
14 14
 require('../common.' . substr(strrchr(__FILE__, '.'), 1));
15 15
 
16
-if($user['authlevel'] < 3) {
16
+if ($user['authlevel'] < 3) {
17 17
   AdminMessage($lang['adm_err_denied']);
18 18
 }
19 19
 
20 20
 $template = gettemplate('admin/settings', true);
21 21
 
22
-if(sys_get_param('save')) {
22
+if (sys_get_param('save')) {
23 23
   $config->game_name               = sys_get_param_str_unsafe('game_name');
24 24
   $config->game_mode               = sys_get_param_int('game_mode');
25 25
   $config->game_speed              = sys_get_param_float('game_speed', 1);
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
   $config->url_faq                 = sys_get_param_str_unsafe('url_faq');
30 30
   $config->url_forum               = sys_get_param_str_unsafe('url_forum');
31 31
   $config->url_rules               = sys_get_param_str_unsafe('url_rules');
32
-  $config->url_purchase_metamatter         = sys_get_param_str_unsafe('url_purchase_metamatter');
32
+  $config->url_purchase_metamatter = sys_get_param_str_unsafe('url_purchase_metamatter');
33 33
   $config->game_disable            = sys_get_param_int('game_disable');
34 34
   $config->game_disable_reason     = sys_get_param_str_unsafe('game_disable_reason');
35 35
   $config->server_updater_check_auto = sys_get_param_int('server_updater_check_auto');
@@ -96,8 +96,8 @@  discard block
 block discarded – undo
96 96
   $config->stats_schedule          = sys_get_param_str('stats_schedule');
97 97
 
98 98
   $config->empire_mercenary_base_period = sys_get_param_int('empire_mercenary_base_period');
99
-  if($config->empire_mercenary_temporary != sys_get_param_int('empire_mercenary_temporary')) {
100
-    if($config->empire_mercenary_temporary) {
99
+  if ($config->empire_mercenary_temporary != sys_get_param_int('empire_mercenary_temporary')) {
100
+    if ($config->empire_mercenary_temporary) {
101 101
       db_unit_list_admin_delete_mercenaries_finished();
102 102
     } else {
103 103
       db_unit_list_admin_set_mercenaries_expire_time($config->empire_mercenary_base_period);
@@ -140,21 +140,21 @@  discard block
 block discarded – undo
140 140
 //  'STATS_SCHEDULE' => $config->stats_hide_player_list,
141 141
 ));
142 142
 
143
-foreach($lang['sys_game_disable_reason'] as $id => $name) {
143
+foreach ($lang['sys_game_disable_reason'] as $id => $name) {
144 144
   $template->assign_block_vars('sys_game_disable_reason', array(
145 145
     'ID'   => $id,
146 146
     'NAME' => $name,
147 147
   ));
148 148
 }
149 149
 
150
-foreach($lang['sys_game_mode'] as $mode_id => $mode_name) {
150
+foreach ($lang['sys_game_mode'] as $mode_id => $mode_name) {
151 151
   $template->assign_block_vars('game_modes', array(
152 152
     'ID'   => $mode_id,
153 153
     'NAME' => $mode_name,
154 154
   ));
155 155
 }
156 156
 
157
-foreach($lang['adm_opt_ver_response'] as $ver_id => $ver_response) {
157
+foreach ($lang['adm_opt_ver_response'] as $ver_id => $ver_response) {
158 158
   $template->assign_block_vars('ver_response', array(
159 159
     'ID'   => $ver_id,
160 160
     'NAME' => js_safe_string($ver_response),
@@ -162,7 +162,7 @@  discard block
 block discarded – undo
162 162
 }
163 163
 
164 164
 $lang_list = lng_get_list();
165
-foreach($lang_list as $lang_id => $lang_data) {
165
+foreach ($lang_list as $lang_id => $lang_data) {
166 166
   $template->assign_block_vars('game_languages', array(
167 167
     'ID'   => $lang_id,
168 168
     'NAME' => "{$lang_data['LANG_NAME_NATIVE']} ({$lang_data['LANG_NAME_ENGLISH']})",
Please login to merge, or discard this patch.
admin/sxd/tmpl.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 // Templates
3
-function sxd_tpl_page(){
3
+function sxd_tpl_page() {
4 4
 global $SXD;
5 5
 return <<<HTML
6 6
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
@@ -291,7 +291,7 @@  discard block
 block discarded – undo
291 291
 HTML;
292 292
 }
293 293
 
294
-function sxd_tpl_auth($error = ''){
294
+function sxd_tpl_auth($error = '') {
295 295
 global $SXD;
296 296
 return <<<HTML
297 297
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">  
Please login to merge, or discard this patch.