@@ -40,8 +40,7 @@ |
||
40 | 40 | if ($this->can_track_by_lastread()) |
41 | 41 | { |
42 | 42 | $info = $this->build_tracking_info('get_topic_tracking', $forums, $topics); |
43 | - } |
|
44 | - else if ($this->can_track_anonymous()) |
|
43 | + } else if ($this->can_track_anonymous()) |
|
45 | 44 | { |
46 | 45 | $info = $this->build_tracking_info('get_complete_topic_tracking', $forums, $topics); |
47 | 46 | } |
@@ -101,8 +101,7 @@ |
||
101 | 101 | if (!isset($key)) |
102 | 102 | { |
103 | 103 | $this->_entities[] = $entity; |
104 | - } |
|
105 | - else |
|
104 | + } else |
|
106 | 105 | { |
107 | 106 | $this->_entities[$key] = $entity; |
108 | 107 | } |
@@ -75,7 +75,7 @@ discard block |
||
75 | 75 | |
76 | 76 | if (sizeof($query_ids)) |
77 | 77 | { |
78 | - $sql_where .= (($sql_where) ? ' AND ' : '') . $this->db->sql_in_set('user_id', $query_ids); |
|
78 | + $sql_where .= (($sql_where) ? ' AND ' : '').$this->db->sql_in_set('user_id', $query_ids); |
|
79 | 79 | $this->query($sql_where); |
80 | 80 | } |
81 | 81 | |
@@ -150,8 +150,8 @@ discard block |
||
150 | 150 | public function get_profile_fields() |
151 | 151 | { |
152 | 152 | $sql = 'SELECT l.lang_name, f.field_ident |
153 | - FROM ' . PROFILE_LANG_TABLE . ' l, ' . PROFILE_FIELDS_TABLE . ' f |
|
154 | - WHERE l.lang_id = ' . $this->user->get_iso_lang_id() . ' |
|
153 | + FROM ' . PROFILE_LANG_TABLE.' l, '.PROFILE_FIELDS_TABLE.' f |
|
154 | + WHERE l.lang_id = ' . $this->user->get_iso_lang_id().' |
|
155 | 155 | AND f.field_active = 1 |
156 | 156 | AND f.field_no_view = 0 |
157 | 157 | AND f.field_hide = 0 |
@@ -203,7 +203,7 @@ discard block |
||
203 | 203 | */ |
204 | 204 | protected function get_search_url($user_id) |
205 | 205 | { |
206 | - return ($this->auth->acl_get('u_search')) ? append_sid($this->phpbb_root_path . 'search.' . $this->php_ext, "author_id=$user_id&sr=posts") : ''; |
|
206 | + return ($this->auth->acl_get('u_search')) ? append_sid($this->phpbb_root_path.'search.'.$this->php_ext, "author_id=$user_id&sr=posts") : ''; |
|
207 | 207 | } |
208 | 208 | |
209 | 209 | /** |
@@ -214,7 +214,7 @@ discard block |
||
214 | 214 | { |
215 | 215 | if (!function_exists('phpbb_get_user_rank')) |
216 | 216 | { |
217 | - include($this->phpbb_root_path . 'includes/functions_display.' . $this->php_ext); |
|
217 | + include($this->phpbb_root_path.'includes/functions_display.'.$this->php_ext); |
|
218 | 218 | } |
219 | 219 | |
220 | 220 | $user_rank_data = phpbb_get_user_rank($row, $row['user_posts']); |
@@ -288,8 +288,8 @@ discard block |
||
288 | 288 | protected function get_sql_statement($sql_where = '', $order_by = '') |
289 | 289 | { |
290 | 290 | return 'SELECT user_id, username, user_type, user_colour, user_avatar, user_avatar_type, user_avatar_height, user_avatar_width, user_regdate, user_lastvisit, user_birthday, user_posts, user_rank, user_allow_viewemail, user_allow_pm, user_jabber, user_inactive_reason |
291 | - FROM ' . USERS_TABLE . |
|
292 | - (($sql_where) ? ' WHERE ' . $sql_where : '') . |
|
293 | - (($order_by) ? ' ORDER BY ' . $order_by : ''); |
|
291 | + FROM ' . USERS_TABLE. |
|
292 | + (($sql_where) ? ' WHERE '.$sql_where : ''). |
|
293 | + (($order_by) ? ' ORDER BY '.$order_by : ''); |
|
294 | 294 | } |
295 | 295 | } |
@@ -91,8 +91,8 @@ discard block |
||
91 | 91 | */ |
92 | 92 | private function clean_styles() |
93 | 93 | { |
94 | - $routes_ary = $this->manager->get_routes_per_style(); |
|
95 | - $style_ids = $this->get_style_ids(); |
|
94 | + $routes_ary = $this->manager->get_routes_per_style(); |
|
95 | + $style_ids = $this->get_style_ids(); |
|
96 | 96 | |
97 | 97 | $routes = array(); |
98 | 98 | foreach ($routes_ary as $style_id => $style_routes) |
@@ -122,7 +122,7 @@ discard block |
||
122 | 122 | |
123 | 123 | foreach ($routes as $route => $row) |
124 | 124 | { |
125 | - $url = $board_url . '/' . (($row['ext_name']) ? 'app.php' : '') . $row['route']; |
|
125 | + $url = $board_url.'/'.(($row['ext_name']) ? 'app.php' : '').$row['route']; |
|
126 | 126 | |
127 | 127 | // Route no longer exists => remove all blocks for route |
128 | 128 | if ($this->url_checker->exists($url) !== true) |
@@ -185,7 +185,7 @@ discard block |
||
185 | 185 | |
186 | 186 | if (sizeof($block_ids)) |
187 | 187 | { |
188 | - $this->db->sql_query('DELETE FROM ' . $this->cblocks_table . ' WHERE ' . $this->db->sql_in_set('block_id', $block_ids)); |
|
188 | + $this->db->sql_query('DELETE FROM '.$this->cblocks_table.' WHERE '.$this->db->sql_in_set('block_id', $block_ids)); |
|
189 | 189 | } |
190 | 190 | } |
191 | 191 |
@@ -62,7 +62,7 @@ discard block |
||
62 | 62 | |
63 | 63 | if (!function_exists('phpbb_get_user_avatar')) |
64 | 64 | { |
65 | - include($phpbb_root_path . 'includes/functions_display.' . $php_ext); |
|
65 | + include($phpbb_root_path.'includes/functions_display.'.$php_ext); |
|
66 | 66 | } |
67 | 67 | } |
68 | 68 | |
@@ -99,8 +99,8 @@ discard block |
||
99 | 99 | */ |
100 | 100 | protected function member_posts(array $row) |
101 | 101 | { |
102 | - $u_posts = append_sid($this->phpbb_root_path . 'search.' . $this->php_ext, "author_id={$row['user_id']}&sr=posts" . $this->explain_range); |
|
103 | - $user_posts = '<a href="' . $u_posts . '">' . $row['user_posts'] . '</a>'; |
|
102 | + $u_posts = append_sid($this->phpbb_root_path.'search.'.$this->php_ext, "author_id={$row['user_id']}&sr=posts".$this->explain_range); |
|
103 | + $user_posts = '<a href="'.$u_posts.'">'.$row['user_posts'].'</a>'; |
|
104 | 104 | |
105 | 105 | return array( |
106 | 106 | 'USERNAME' => get_username_string('full', $row['user_id'], $row['username'], $row['user_colour']), |
@@ -168,7 +168,7 @@ discard block |
||
168 | 168 | 'WHERE' => $this->db->sql_in_set('u.user_type', array(USER_NORMAL, USER_FOUNDER)), |
169 | 169 | ); |
170 | 170 | |
171 | - $sql_method = 'set_' . $this->settings['query_type'] . '_sql'; |
|
171 | + $sql_method = 'set_'.$this->settings['query_type'].'_sql'; |
|
172 | 172 | call_user_func_array(array($this, $sql_method), array(&$sql_ary)); |
173 | 173 | |
174 | 174 | $this->set_range_sql($sql_ary); |
@@ -198,7 +198,7 @@ discard block |
||
198 | 198 | $this->info_header = ''; |
199 | 199 | $this->view_mode = 'member_bots'; |
200 | 200 | |
201 | - $sql_ary['WHERE'] = 'u.user_type = ' . USER_IGNORE; |
|
201 | + $sql_ary['WHERE'] = 'u.user_type = '.USER_IGNORE; |
|
202 | 202 | } |
203 | 203 | |
204 | 204 | /** |
@@ -207,7 +207,7 @@ discard block |
||
207 | 207 | protected function set_tenured_sql(array &$sql_ary) |
208 | 208 | { |
209 | 209 | $sql_ary['SELECT'] .= ', u.user_regdate as member_date'; |
210 | - $sql_ary['ORDER_BY'] = 'u.user_regdate ' . (($this->settings['query_type'] == 'tenured') ? 'ASC' : 'DESC'); |
|
210 | + $sql_ary['ORDER_BY'] = 'u.user_regdate '.(($this->settings['query_type'] == 'tenured') ? 'ASC' : 'DESC'); |
|
211 | 211 | |
212 | 212 | $this->sql_date_field = 'u.user_regdate'; |
213 | 213 | $this->settings['date_range'] = ''; |
@@ -230,7 +230,7 @@ discard block |
||
230 | 230 | $sql_ary['SELECT'] .= ', COUNT(p.post_id) as user_posts'; |
231 | 231 | $sql_ary['FROM'] += array(TOPICS_TABLE => 't'); |
232 | 232 | $sql_ary['FROM'] += array(POSTS_TABLE => 'p'); |
233 | - $sql_ary['WHERE'] .= ' AND ' . time() . ' > t.topic_time AND t.topic_id = p.topic_id AND p.post_visibility = ' . ITEM_APPROVED . ' AND p.poster_id = u.user_id'; |
|
233 | + $sql_ary['WHERE'] .= ' AND '.time().' > t.topic_time AND t.topic_id = p.topic_id AND p.post_visibility = '.ITEM_APPROVED.' AND p.poster_id = u.user_id'; |
|
234 | 234 | $sql_ary['GROUP_BY'] = 'u.user_id'; |
235 | 235 | $sql_ary['ORDER_BY'] = 'user_posts DESC, u.username ASC'; |
236 | 236 | |
@@ -247,7 +247,7 @@ discard block |
||
247 | 247 | if ($this->settings['date_range'] && $this->sql_date_field) |
248 | 248 | { |
249 | 249 | $range = $this->date_range->get($this->settings['date_range']); |
250 | - $this->explain_range = '&date=' . $range['date']; |
|
250 | + $this->explain_range = '&date='.$range['date']; |
|
251 | 251 | |
252 | 252 | $sql_ary['WHERE'] .= " AND {$this->sql_date_field} BETWEEN {$range['start']} AND {$range['stop']}"; |
253 | 253 | } |
@@ -96,13 +96,13 @@ discard block |
||
96 | 96 | public function set_javascript_data($route, $style_id) |
97 | 97 | { |
98 | 98 | $board_url = generate_board_url(); |
99 | - $ajax_url = $board_url . ((!$this->config['enable_mod_rewrite']) ? '/app.' . $this->php_ext : ''); |
|
99 | + $ajax_url = $board_url.((!$this->config['enable_mod_rewrite']) ? '/app.'.$this->php_ext : ''); |
|
100 | 100 | |
101 | 101 | $is_default_route = $u_default_route = false; |
102 | 102 | if ($this->config['sitemaker_default_layout']) |
103 | 103 | { |
104 | 104 | $is_default_route = ($this->config['sitemaker_default_layout'] === $route) ? true : false; |
105 | - $u_default_route .= $board_url . '/' . $this->config['sitemaker_default_layout']; |
|
105 | + $u_default_route .= $board_url.'/'.$this->config['sitemaker_default_layout']; |
|
106 | 106 | $u_default_route = reapply_sid($u_default_route); |
107 | 107 | } |
108 | 108 | |
@@ -149,7 +149,7 @@ discard block |
||
149 | 149 | list($controller_service, $controller_method) = explode(':', $controller); |
150 | 150 | $controller_params = $symfony_request->attributes->get('_route_params'); |
151 | 151 | $controller_object = $this->phpbb_container->get($controller_service); |
152 | - $controller_class = get_class($controller_object); |
|
152 | + $controller_class = get_class($controller_object); |
|
153 | 153 | |
154 | 154 | $r = new \ReflectionMethod($controller_class, $controller_method); |
155 | 155 | $class_params = $r->getParameters(); |
@@ -162,7 +162,7 @@ discard block |
||
162 | 162 | 'CONTROLLER_METHOD' => $controller_method, |
163 | 163 | 'CONTROLLER_PARAMS' => $controller_arguments, |
164 | 164 | 'S_IS_STARTPAGE' => $this->is_startpage($controller_service, $controller_arguments), |
165 | - 'UA_EXTENSION' => $namespace . '/' . $extension, |
|
165 | + 'UA_EXTENSION' => $namespace.'/'.$extension, |
|
166 | 166 | )); |
167 | 167 | } |
168 | 168 | } |
@@ -197,11 +197,11 @@ discard block |
||
197 | 197 | { |
198 | 198 | $routes_ary = $this->get_routes(); |
199 | 199 | |
200 | - $options = '<option value="">' . $this->translator->lang('SELECT') . '</option>'; |
|
200 | + $options = '<option value="">'.$this->translator->lang('SELECT').'</option>'; |
|
201 | 201 | foreach ($routes_ary as $route) |
202 | 202 | { |
203 | 203 | $selected = ($route == $current_route) ? ' selected="selected"' : ''; |
204 | - $options .= '<option value="' . $route . '"' . $selected . '>' . $route . '</option>'; |
|
204 | + $options .= '<option value="'.$route.'"'.$selected.'>'.$route.'</option>'; |
|
205 | 205 | } |
206 | 206 | |
207 | 207 | return $options; |
@@ -215,10 +215,10 @@ discard block |
||
215 | 215 | */ |
216 | 216 | public function get_excluded_position_options(array $ex_positions) |
217 | 217 | { |
218 | - $options = '<option value=""' . ((!sizeof($ex_positions)) ? ' selected="selected"' : '') . '>' . $this->translator->lang('NONE') . '</option>'; |
|
218 | + $options = '<option value=""'.((!sizeof($ex_positions)) ? ' selected="selected"' : '').'>'.$this->translator->lang('NONE').'</option>'; |
|
219 | 219 | foreach ($ex_positions as $position) |
220 | 220 | { |
221 | - $options .= '<option value="' . $position . '" selected="selected">' . $position . '</option>'; |
|
221 | + $options .= '<option value="'.$position.'" selected="selected">'.$position.'</option>'; |
|
222 | 222 | } |
223 | 223 | |
224 | 224 | return $options; |
@@ -59,6 +59,6 @@ |
||
59 | 59 | $class_name = get_class($block_instance); |
60 | 60 | list($namespace, $extension) = explode('\\', $class_name); |
61 | 61 | |
62 | - return $namespace . '/' . $extension; |
|
62 | + return $namespace.'/'.$extension; |
|
63 | 63 | } |
64 | 64 | } |
@@ -63,7 +63,7 @@ |
||
63 | 63 | */ |
64 | 64 | public function create($action) |
65 | 65 | { |
66 | - $action_class = 'blitze\\sitemaker\\services\\blocks\\action\\' . $action; |
|
66 | + $action_class = 'blitze\\sitemaker\\services\\blocks\\action\\'.$action; |
|
67 | 67 | |
68 | 68 | if (!class_exists($action_class)) |
69 | 69 | { |
@@ -38,7 +38,7 @@ |
||
38 | 38 | $time = $this->user->create_datetime($this->time); |
39 | 39 | $now = phpbb_gmgetdate($time->getTimestamp() + $time->getOffset()); |
40 | 40 | |
41 | - $method = 'get_' . $range; |
|
41 | + $method = 'get_'.$range; |
|
42 | 42 | $data = array( |
43 | 43 | 'start' => 0, |
44 | 44 | 'stop' => 0, |
@@ -64,8 +64,8 @@ discard block |
||
64 | 64 | $default_lang_files = $finder |
65 | 65 | ->prefix($lang_file) |
66 | 66 | ->suffix(".$this->php_ext") |
67 | - ->extension_directory('/language/' . basename($this->config['default_lang'])) |
|
68 | - ->core_path('language/' . basename($this->config['default_lang']) . '/') |
|
67 | + ->extension_directory('/language/'.basename($this->config['default_lang'])) |
|
68 | + ->core_path('language/'.basename($this->config['default_lang']).'/') |
|
69 | 69 | ->find(); |
70 | 70 | } |
71 | 71 | |
@@ -84,8 +84,8 @@ discard block |
||
84 | 84 | $user_lang_files = $finder |
85 | 85 | ->prefix($lang_file) |
86 | 86 | ->suffix(".$this->php_ext") |
87 | - ->extension_directory('/language/' . $this->user->lang_name) |
|
88 | - ->core_path('language/' . $this->user->lang_name . '/') |
|
87 | + ->extension_directory('/language/'.$this->user->lang_name) |
|
88 | + ->core_path('language/'.$this->user->lang_name.'/') |
|
89 | 89 | ->find(); |
90 | 90 | |
91 | 91 | $lang_files = array_unique(array_merge($user_lang_files, $english_lang_files, $default_lang_files)); |