@@ -45,11 +45,11 @@ |
||
| 45 | 45 | $curr_key = (int) array_search($settings['current_user'], $userlist); |
| 46 | 46 | |
| 47 | 47 | // Remove the invalid user from the list |
| 48 | - $new_list = str_replace($settings['current_user'] . ',', '', $settings['userlist'] . ','); |
|
| 48 | + $new_list = str_replace($settings['current_user'].',', '', $settings['userlist'].','); |
|
| 49 | 49 | $new_list = trim($new_list, ','); |
| 50 | 50 | |
| 51 | 51 | $new_userlist = self::_get_userlist($new_list); |
| 52 | - $current_user =& $new_userlist[$curr_key - 1]; |
|
| 52 | + $current_user = & $new_userlist[$curr_key - 1]; |
|
| 53 | 53 | $settings['current_user'] = (int) $current_user; |
| 54 | 54 | $settings['userlist'] = trim($new_list); |
| 55 | 55 | $settings['last_changed'] = 0; |
@@ -96,7 +96,7 @@ discard block |
||
| 96 | 96 | */ |
| 97 | 97 | protected function get_email_url(array $row) |
| 98 | 98 | { |
| 99 | - return ($this->email_form_allowed) ? append_sid("{$this->phpbb_root_path}memberlist.{$this->php_ext}", 'mode=email&u=' . $row['user_id']) : (($this->mailto_allowed) ? 'mailto:' . $row['user_email'] : ''); |
|
| 99 | + return ($this->email_form_allowed) ? append_sid("{$this->phpbb_root_path}memberlist.{$this->php_ext}", 'mode=email&u='.$row['user_id']) : (($this->mailto_allowed) ? 'mailto:'.$row['user_email'] : ''); |
|
| 100 | 100 | } |
| 101 | 101 | |
| 102 | 102 | /** |
@@ -127,7 +127,7 @@ discard block |
||
| 127 | 127 | $jabber = array( |
| 128 | 128 | 'ID' => 'jabber', |
| 129 | 129 | 'NAME' => $this->translator->lang('JABBER'), |
| 130 | - 'U_CONTACT' => append_sid("{$this->phpbb_root_path}memberlist.{$this->php_ext}", 'mode=contact&action=jabber&u=' . $row['user_id']), |
|
| 130 | + 'U_CONTACT' => append_sid("{$this->phpbb_root_path}memberlist.{$this->php_ext}", 'mode=contact&action=jabber&u='.$row['user_id']), |
|
| 131 | 131 | ); |
| 132 | 132 | } |
| 133 | 133 | |
@@ -156,7 +156,7 @@ discard block |
||
| 156 | 156 | $pm = array( |
| 157 | 157 | 'ID' => 'pm', |
| 158 | 158 | 'NAME' => $this->translator->lang('SEND_PRIVATE_MESSAGE'), |
| 159 | - 'U_CONTACT' => append_sid("{$this->phpbb_root_path}ucp.{$this->php_ext}", 'i=pm&mode=compose&u=' . $row['user_id']), |
|
| 159 | + 'U_CONTACT' => append_sid("{$this->phpbb_root_path}ucp.{$this->php_ext}", 'i=pm&mode=compose&u='.$row['user_id']), |
|
| 160 | 160 | ); |
| 161 | 161 | } |
| 162 | 162 | |
@@ -219,7 +219,7 @@ discard block |
||
| 219 | 219 | { |
| 220 | 220 | if (!function_exists('phpbb_get_banned_user_ids')) |
| 221 | 221 | { |
| 222 | - include($this->phpbb_root_path . 'includes/functions_user.' . $this->php_ext); |
|
| 222 | + include($this->phpbb_root_path.'includes/functions_user.'.$this->php_ext); |
|
| 223 | 223 | } |
| 224 | 224 | |
| 225 | 225 | return phpbb_get_banned_user_ids($user_ids, false); |
@@ -147,7 +147,7 @@ discard block |
||
| 147 | 147 | private function change_user() |
| 148 | 148 | { |
| 149 | 149 | $change = false; |
| 150 | - if ($this->settings['rotation'] == 'pageload' || $this->settings['last_changed'] < strtotime('-1 ' . self::$rotations[$this->settings['rotation']])) |
|
| 150 | + if ($this->settings['rotation'] == 'pageload' || $this->settings['last_changed'] < strtotime('-1 '.self::$rotations[$this->settings['rotation']])) |
|
| 151 | 151 | { |
| 152 | 152 | $this->settings['last_changed'] = time(); |
| 153 | 153 | $change = true; |
@@ -162,7 +162,7 @@ discard block |
||
| 162 | 162 | */ |
| 163 | 163 | private function get_settings(array $bdata) |
| 164 | 164 | { |
| 165 | - $cached_settings = $this->cache->get('pt_block_data_' . $bdata['bid']); |
|
| 165 | + $cached_settings = $this->cache->get('pt_block_data_'.$bdata['bid']); |
|
| 166 | 166 | $settings = ($cached_settings && $cached_settings['hash'] === $bdata['hash']) ? $cached_settings : $bdata['settings']; |
| 167 | 167 | $settings['hash'] = $bdata['hash']; |
| 168 | 168 | |
@@ -182,8 +182,8 @@ discard block |
||
| 182 | 182 | $sql_data = array( |
| 183 | 183 | 'settings' => json_encode($settings) |
| 184 | 184 | ); |
| 185 | - $this->db->sql_query('UPDATE ' . $this->blocks_table . ' SET ' . $this->db->sql_build_array('UPDATE', $sql_data) . ' WHERE bid = ' . (int) $bid); |
|
| 186 | - $this->cache->put('pt_block_data_' . $bid, $this->settings); |
|
| 185 | + $this->db->sql_query('UPDATE '.$this->blocks_table.' SET '.$this->db->sql_build_array('UPDATE', $sql_data).' WHERE bid = '.(int) $bid); |
|
| 186 | + $this->cache->put('pt_block_data_'.$bid, $this->settings); |
|
| 187 | 187 | } |
| 188 | 188 | } |
| 189 | 189 | |
@@ -235,8 +235,8 @@ discard block |
||
| 235 | 235 | $rotation = $this->settings['rotation']; |
| 236 | 236 | |
| 237 | 237 | $this->ptemplate->assign_vars(array( |
| 238 | - 'QTYPE_EXPLAIN' => ($query_type == 'posts' || $query_type == 'recent') ? $this->translator->lang('QTYPE_' . strtoupper($query_type)) : '', |
|
| 239 | - 'TITLE_EXPLAIN' => ($rotation != 'pageload') ? $this->translator->lang(strtoupper($rotation) . '_MEMBER') : '', |
|
| 238 | + 'QTYPE_EXPLAIN' => ($query_type == 'posts' || $query_type == 'recent') ? $this->translator->lang('QTYPE_'.strtoupper($query_type)) : '', |
|
| 239 | + 'TITLE_EXPLAIN' => ($rotation != 'pageload') ? $this->translator->lang(strtoupper($rotation).'_MEMBER') : '', |
|
| 240 | 240 | )); |
| 241 | 241 | } |
| 242 | 242 | |
@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | */ |
| 50 | 50 | public function display(array $bdata, $edit_mode = false) |
| 51 | 51 | { |
| 52 | - if (($content = $this->cache->get('pt_block_data_' . $bdata['bid'])) === false) |
|
| 52 | + if (($content = $this->cache->get('pt_block_data_'.$bdata['bid'])) === false) |
|
| 53 | 53 | { |
| 54 | 54 | $content = ''; |
| 55 | 55 | if ($this->find_birthday_users()) |
@@ -57,7 +57,7 @@ discard block |
||
| 57 | 57 | $content = $this->ptemplate->render_view('blitze/sitemaker', 'blocks/birthday.html', 'birthday_block'); |
| 58 | 58 | |
| 59 | 59 | // we only check birthdays every hour, may make this an admin choice |
| 60 | - $this->cache->put('pt_block_data_' . $bdata['bid'], $content, 3600); |
|
| 60 | + $this->cache->put('pt_block_data_'.$bdata['bid'], $content, 3600); |
|
| 61 | 61 | } |
| 62 | 62 | } |
| 63 | 63 | |
@@ -78,12 +78,12 @@ discard block |
||
| 78 | 78 | $leap_year_birthdays = $this->adjust_leap_year($now, $time); |
| 79 | 79 | |
| 80 | 80 | $sql = 'SELECT u.user_id, u.username, u.user_colour, u.user_birthday |
| 81 | - FROM ' . USERS_TABLE . ' u |
|
| 82 | - LEFT JOIN ' . BANLIST_TABLE . " b ON (u.user_id = b.ban_userid) |
|
| 81 | + FROM ' . USERS_TABLE.' u |
|
| 82 | + LEFT JOIN ' . BANLIST_TABLE." b ON (u.user_id = b.ban_userid) |
|
| 83 | 83 | WHERE (b.ban_id IS NULL |
| 84 | 84 | OR b.ban_exclude = 1) |
| 85 | - AND (u.user_birthday " . $this->db->sql_like_expression(sprintf('%2d-%2d-', $now['mday'], $now['mon']) . $this->db->get_any_char()) . " $leap_year_birthdays) |
|
| 86 | - AND u.user_type IN (" . USER_NORMAL . ', ' . USER_FOUNDER . ') |
|
| 85 | + AND (u.user_birthday " . $this->db->sql_like_expression(sprintf('%2d-%2d-', $now['mday'], $now['mon']).$this->db->get_any_char())." $leap_year_birthdays) |
|
| 86 | + AND u.user_type IN (".USER_NORMAL.', '.USER_FOUNDER.') |
|
| 87 | 87 | ORDER BY u.username ASC'; |
| 88 | 88 | $result = $this->db->sql_query($sql); |
| 89 | 89 | |
@@ -113,7 +113,7 @@ discard block |
||
| 113 | 113 | $leap_year_birthdays = ''; |
| 114 | 114 | if ($now['mday'] == 28 && $now['mon'] == 2 && !$time->format('L')) |
| 115 | 115 | { |
| 116 | - $leap_year_birthdays = ' OR u.user_birthday ' . $this->db->sql_like_expression(sprintf('%2d-%2d-', 29, 2) . $this->db->get_any_char()); |
|
| 116 | + $leap_year_birthdays = ' OR u.user_birthday '.$this->db->sql_like_expression(sprintf('%2d-%2d-', 29, 2).$this->db->get_any_char()); |
|
| 117 | 117 | } |
| 118 | 118 | |
| 119 | 119 | return $leap_year_birthdays; |
@@ -103,7 +103,7 @@ discard block |
||
| 103 | 103 | */ |
| 104 | 104 | public function get_default_avatar() |
| 105 | 105 | { |
| 106 | - return '<img src="' . $this->get_theme_path() . '/images/no_avatar.gif" alt="" />'; |
|
| 106 | + return '<img src="'.$this->get_theme_path().'/images/no_avatar.gif" alt="" />'; |
|
| 107 | 107 | } |
| 108 | 108 | |
| 109 | 109 | /** |
@@ -113,7 +113,7 @@ discard block |
||
| 113 | 113 | public function get_theme_path() |
| 114 | 114 | { |
| 115 | 115 | $web_path = $this->get_web_path(); |
| 116 | - return "{$web_path}styles/" . rawurlencode($this->user->style['style_path']) . '/theme'; |
|
| 116 | + return "{$web_path}styles/".rawurlencode($this->user->style['style_path']).'/theme'; |
|
| 117 | 117 | } |
| 118 | 118 | |
| 119 | 119 | /** |
@@ -123,7 +123,7 @@ discard block |
||
| 123 | 123 | public function get_web_path() |
| 124 | 124 | { |
| 125 | 125 | // Determine board url - we may need it later |
| 126 | - $board_url = generate_board_url() . '/'; |
|
| 126 | + $board_url = generate_board_url().'/'; |
|
| 127 | 127 | |
| 128 | 128 | $corrected_path = $this->path_helper->get_web_root_path(); |
| 129 | 129 | return (defined('PHPBB_USE_BOARD_URL_PATH') && PHPBB_USE_BOARD_URL_PATH) ? $board_url : $corrected_path; |
@@ -50,7 +50,7 @@ |
||
| 50 | 50 | '@blitze_sitemaker/assets/icons/picker.min.js', |
| 51 | 51 | ), |
| 52 | 52 | 'css' => array( |
| 53 | - defined('IN_ADMIN') ? $this->util->get_web_path() . 'assets/css/font-awesome.min.css' : '', |
|
| 53 | + defined('IN_ADMIN') ? $this->util->get_web_path().'assets/css/font-awesome.min.css' : '', |
|
| 54 | 54 | '@blitze_sitemaker/vendor/jquery-ui/themes/smoothness/jquery-ui.min.css', |
| 55 | 55 | '@blitze_sitemaker/assets/icons/picker.min.css', |
| 56 | 56 | ) |
@@ -59,12 +59,12 @@ |
||
| 59 | 59 | * to fix relative paths for forum images |
| 60 | 60 | */ |
| 61 | 61 | global $phpbb_root_path; |
| 62 | - $phpbb_root_path = generate_board_url() . '/'; |
|
| 62 | + $phpbb_root_path = generate_board_url().'/'; |
|
| 63 | 63 | |
| 64 | 64 | // @codeCoverageIgnoreStart |
| 65 | 65 | if (!function_exists('display_forums')) |
| 66 | 66 | { |
| 67 | - include($this->phpbb_root_path . 'includes/functions_display.' . $this->php_ext); |
|
| 67 | + include($this->phpbb_root_path.'includes/functions_display.'.$this->php_ext); |
|
| 68 | 68 | } |
| 69 | 69 | // @codeCoverageIgnoreEnd |
| 70 | 70 | |
@@ -175,12 +175,12 @@ |
||
| 175 | 175 | { |
| 176 | 176 | if ($page_dir) |
| 177 | 177 | { |
| 178 | - $route = ltrim(dirname($page_dir) . '/index.php', './'); |
|
| 178 | + $route = ltrim(dirname($page_dir).'/index.php', './'); |
|
| 179 | 179 | $parent_route = $this->get_parent_route_info($routes, $route); |
| 180 | 180 | } |
| 181 | - else if ($current_route === 'viewtopic.' . $this->php_ext) |
|
| 181 | + else if ($current_route === 'viewtopic.'.$this->php_ext) |
|
| 182 | 182 | { |
| 183 | - $route = 'viewforum.' . $this->php_ext; |
|
| 183 | + $route = 'viewforum.'.$this->php_ext; |
|
| 184 | 184 | $parent_route = $this->get_parent_route_info($routes, $route); |
| 185 | 185 | } |
| 186 | 186 | else |
@@ -61,7 +61,7 @@ discard block |
||
| 61 | 61 | // @codeCoverageIgnoreStart |
| 62 | 62 | if (!function_exists('build_cfg_template')) |
| 63 | 63 | { |
| 64 | - include($this->phpbb_root_path . 'includes/functions_acp.' . $this->php_ext); |
|
| 64 | + include($this->phpbb_root_path.'includes/functions_acp.'.$this->php_ext); |
|
| 65 | 65 | } |
| 66 | 66 | // @codeCoverageIgnoreEnd |
| 67 | 67 | |
@@ -100,7 +100,7 @@ discard block |
||
| 100 | 100 | // @codeCoverageIgnoreStart |
| 101 | 101 | if (!function_exists('validate_config_vars')) |
| 102 | 102 | { |
| 103 | - include($this->phpbb_root_path . 'includes/functions_acp.' . $this->php_ext); |
|
| 103 | + include($this->phpbb_root_path.'includes/functions_acp.'.$this->php_ext); |
|
| 104 | 104 | } |
| 105 | 105 | // @codeCoverageIgnoreEnd |
| 106 | 106 | |
@@ -203,7 +203,7 @@ discard block |
||
| 203 | 203 | if (empty($vars['object'])) |
| 204 | 204 | { |
| 205 | 205 | $object = $this; |
| 206 | - $method = 'prep_' . $type[0] . '_field_for_display'; |
|
| 206 | + $method = 'prep_'.$type[0].'_field_for_display'; |
|
| 207 | 207 | |
| 208 | 208 | if (is_callable(array($this, $method))) |
| 209 | 209 | { |
@@ -257,7 +257,7 @@ discard block |
||
| 257 | 257 | $l_explain = ''; |
| 258 | 258 | if (!empty($vars['explain'])) |
| 259 | 259 | { |
| 260 | - $l_explain = (isset($vars['lang_explain'])) ? $this->translator->lang($vars['lang_explain']) : $this->translator->lang($vars['lang'] . '_EXPLAIN'); |
|
| 260 | + $l_explain = (isset($vars['lang_explain'])) ? $this->translator->lang($vars['lang_explain']) : $this->translator->lang($vars['lang'].'_EXPLAIN'); |
|
| 261 | 261 | } |
| 262 | 262 | |
| 263 | 263 | return $l_explain; |
@@ -357,7 +357,7 @@ discard block |
||
| 357 | 357 | { |
| 358 | 358 | $this->prep_checkbox_field_for_display($vars, $type, $field); |
| 359 | 359 | |
| 360 | - $vars['method'] ='build_multi_select'; |
|
| 360 | + $vars['method'] = 'build_multi_select'; |
|
| 361 | 361 | } |
| 362 | 362 | |
| 363 | 363 | /** |