@@ -121,7 +121,7 @@ |
||
121 | 121 | $this->find_parents($data, $row['parent_id']); |
122 | 122 | } |
123 | 123 | } |
124 | - */ |
|
124 | + */ |
|
125 | 125 | |
126 | 126 | /** |
127 | 127 | * @param array $data |
@@ -70,7 +70,7 @@ discard block |
||
70 | 70 | * @param string $handle |
71 | 71 | * @return void |
72 | 72 | */ |
73 | - public function display_navlist(array $data, \phpbb\template\twig\twig &$template, $handle = 'tree') |
|
73 | + public function display_navlist(array $data, \phpbb\template\twig\twig & $template, $handle = 'tree') |
|
74 | 74 | { |
75 | 75 | $this->set_current_item($data); |
76 | 76 | $this->prepare_items($data['items']); |
@@ -85,10 +85,10 @@ discard block |
||
85 | 85 | $row['num_kids'] = $this->count_descendants($row); |
86 | 86 | |
87 | 87 | $template->assign_block_vars($handle, array_change_key_case($row, CASE_UPPER)); |
88 | - $this->close_open_tags($template, $handle . '.close', abs($prev_depth - $this_depth)); |
|
88 | + $this->close_open_tags($template, $handle.'.close', abs($prev_depth - $this_depth)); |
|
89 | 89 | } |
90 | 90 | |
91 | - $this->close_open_tags($template, 'close_' . $handle, ($this_depth - $this->min_depth)); |
|
91 | + $this->close_open_tags($template, 'close_'.$handle, ($this_depth - $this->min_depth)); |
|
92 | 92 | } |
93 | 93 | } |
94 | 94 | |
@@ -156,12 +156,12 @@ discard block |
||
156 | 156 | */ |
157 | 157 | protected function get_current_path() |
158 | 158 | { |
159 | - $curr_page = '/' . ltrim($this->user->page['page_dir'] . '/' . $this->user->page['page_name'], './'); |
|
159 | + $curr_page = '/'.ltrim($this->user->page['page_dir'].'/'.$this->user->page['page_name'], './'); |
|
160 | 160 | $curr_parts = explode('&', $this->user->page['query_string']); |
161 | 161 | |
162 | 162 | sort($curr_parts); |
163 | 163 | |
164 | - return $curr_page . '?' . join('&', $curr_parts); |
|
164 | + return $curr_page.'?'.join('&', $curr_parts); |
|
165 | 165 | } |
166 | 166 | |
167 | 167 | /** |
@@ -203,7 +203,7 @@ discard block |
||
203 | 203 | |
204 | 204 | $is_current_item = $this->is_current_item($row); |
205 | 205 | $is_parent = $this->is_parent_of_current_item($row); |
206 | - $this_depth = $this->parental_depth[$row['parent_id']] + 1; |
|
206 | + $this_depth = $this->parental_depth[$row['parent_id']] + 1; |
|
207 | 207 | $leaf = $this->get_leaf_node($row, $is_current_item, $is_parent); |
208 | 208 | |
209 | 209 | $this->parental_depth[$row[$this->pk]] = $this_depth; |
@@ -284,7 +284,7 @@ discard block |
||
284 | 284 | * @param int $repeat |
285 | 285 | * @return void |
286 | 286 | */ |
287 | - protected function close_open_tags(\phpbb\template\twig\twig &$template, $handle, $repeat) |
|
287 | + protected function close_open_tags(\phpbb\template\twig\twig & $template, $handle, $repeat) |
|
288 | 288 | { |
289 | 289 | for ($i = 0; $i < $repeat; $i++) |
290 | 290 | { |
@@ -120,13 +120,13 @@ |
||
120 | 120 | */ |
121 | 121 | public function set_startpage() |
122 | 122 | { |
123 | - if ($this->user->page['page_name'] == 'index.' . $this->php_ext && !$this->is_startpage && ($controller_object = $this->get_startpage_controller()) !== false) |
|
123 | + if ($this->user->page['page_name'] == 'index.'.$this->php_ext && !$this->is_startpage && ($controller_object = $this->get_startpage_controller()) !== false) |
|
124 | 124 | { |
125 | 125 | $method = $this->config['sitemaker_startpage_method']; |
126 | 126 | $this->is_startpage = true; |
127 | 127 | |
128 | 128 | $controller_dir = explode('\\', get_class($controller_object)); |
129 | - $controller_style_dir = 'ext/' . $controller_dir[0] . '/' . $controller_dir[1] . '/styles'; |
|
129 | + $controller_style_dir = 'ext/'.$controller_dir[0].'/'.$controller_dir[1].'/styles'; |
|
130 | 130 | $this->template->set_style(array($controller_style_dir, 'styles')); |
131 | 131 | |
132 | 132 | $arguments = explode('/', $this->config['sitemaker_startpage_params']); |
@@ -68,9 +68,9 @@ discard block |
||
68 | 68 | public function load_permission_language(\phpbb\event\data $event) |
69 | 69 | { |
70 | 70 | $permissions = $event['permissions']; |
71 | - $permissions['a_sm_settings'] = array('lang' => 'ACL_A_SM_SETTINGS', 'cat' => 'misc'); |
|
72 | - $permissions['a_sm_manage_blocks'] = array('lang' => 'ACL_A_SM_MANAGE_BLOCKS', 'cat' => 'misc'); |
|
73 | - $permissions['a_sm_manage_menus'] = array('lang' => 'ACL_A_SM_MANAGE_MENUS', 'cat' => 'misc'); |
|
71 | + $permissions['a_sm_settings'] = array('lang' => 'ACL_A_SM_SETTINGS', 'cat' => 'misc'); |
|
72 | + $permissions['a_sm_manage_blocks'] = array('lang' => 'ACL_A_SM_MANAGE_BLOCKS', 'cat' => 'misc'); |
|
73 | + $permissions['a_sm_manage_menus'] = array('lang' => 'ACL_A_SM_MANAGE_MENUS', 'cat' => 'misc'); |
|
74 | 74 | $event['permissions'] = $permissions; |
75 | 75 | } |
76 | 76 | |
@@ -79,7 +79,7 @@ discard block |
||
79 | 79 | */ |
80 | 80 | public function add_viewonline_location(\phpbb\event\data $event) |
81 | 81 | { |
82 | - if ($event['on_page'][1] == 'app' && strrpos($event['row']['session_page'], 'app.' . $this->php_ext . '/forum') === 0) |
|
82 | + if ($event['on_page'][1] == 'app' && strrpos($event['row']['session_page'], 'app.'.$this->php_ext.'/forum') === 0) |
|
83 | 83 | { |
84 | 84 | $event['location'] = $this->translator->lang('FORUM_INDEX'); |
85 | 85 | $event['location_url'] = $this->phpbb_container->get('controller.helper')->route('blitze_sitemaker_forum'); |
@@ -76,8 +76,7 @@ |
||
76 | 76 | { |
77 | 77 | $file->remove(); |
78 | 78 | $json_data['message'] = implode('<br />', $file->error); |
79 | - } |
|
80 | - else |
|
79 | + } else |
|
81 | 80 | { |
82 | 81 | $json_data['location'] = $file->get('realname'); |
83 | 82 | } |
@@ -88,7 +88,7 @@ discard block |
||
88 | 88 | * @param \phpbb\files\filespec $file |
89 | 89 | * @return void |
90 | 90 | */ |
91 | - protected function set_filename(\phpbb\files\filespec &$file) |
|
91 | + protected function set_filename(\phpbb\files\filespec & $file) |
|
92 | 92 | { |
93 | 93 | $mode = 'real'; |
94 | 94 | $prefix = ''; |
@@ -107,7 +107,7 @@ discard block |
||
107 | 107 | */ |
108 | 108 | protected function get_file() |
109 | 109 | { |
110 | - $upload_dir = $this->phpbb_root_path . 'images/sitemaker_uploads/source/'; |
|
110 | + $upload_dir = $this->phpbb_root_path.'images/sitemaker_uploads/source/'; |
|
111 | 111 | |
112 | 112 | $file = $this->files_factory->get('files.upload') |
113 | 113 | ->set_disallowed_content(array()) |
@@ -105,6 +105,6 @@ |
||
105 | 105 | */ |
106 | 106 | private function get_viewonline_url() |
107 | 107 | { |
108 | - return ($this->auth->acl_gets('u_viewprofile', 'a_user', 'a_useradd', 'a_userdel')) ? append_sid("{$this->phpbb_root_path}viewonline." . $this->php_ext) : ''; |
|
108 | + return ($this->auth->acl_gets('u_viewprofile', 'a_user', 'a_useradd', 'a_userdel')) ? append_sid("{$this->phpbb_root_path}viewonline.".$this->php_ext) : ''; |
|
109 | 109 | } |
110 | 110 | } |
@@ -69,8 +69,7 @@ |
||
69 | 69 | if ($data['TOTAL_USERS_ONLINE']) |
70 | 70 | { |
71 | 71 | list($l_online_users, $online_userlist, $l_online_record) = array_values($data); |
72 | - } |
|
73 | - else |
|
72 | + } else |
|
74 | 73 | { |
75 | 74 | $item_id = 0; |
76 | 75 | $item = 'forum'; |
@@ -92,7 +92,7 @@ discard block |
||
92 | 92 | 'MENU_ID' => $menu_id, |
93 | 93 | 'ICON_PICKER' => $this->icon->picker(), |
94 | 94 | 'T_PATH' => $this->phpbb_root_path, |
95 | - 'UA_AJAX_URL' => $this->controller_helper->route('blitze_sitemaker_menus_admin', array(), true, '') . '/', |
|
95 | + 'UA_AJAX_URL' => $this->controller_helper->route('blitze_sitemaker_menus_admin', array(), true, '').'/', |
|
96 | 96 | )); |
97 | 97 | |
98 | 98 | $this->tpl_name = 'acp_menu'; |
@@ -146,7 +146,7 @@ discard block |
||
146 | 146 | $vars = array('bulk_options', 'forumslist'); |
147 | 147 | extract($this->phpbb_dispatcher->trigger_event('blitze.sitemaker.acp_add_bulk_menu_options', compact($vars))); |
148 | 148 | |
149 | - $bulk_options['FORUMS'] = $this->get_forums_string($forumslist); |
|
149 | + $bulk_options['FORUMS'] = $this->get_forums_string($forumslist); |
|
150 | 150 | |
151 | 151 | $this->template->assign_var('bulk_options', $bulk_options); |
152 | 152 | } |
@@ -161,7 +161,7 @@ discard block |
||
161 | 161 | foreach ($forumslist as $forum_id => $row) |
162 | 162 | { |
163 | 163 | $text .= str_replace(' ', "\t", $row['padding']); |
164 | - $text .= $row['forum_name'] . '|'; |
|
164 | + $text .= $row['forum_name'].'|'; |
|
165 | 165 | $text .= "viewforum.{$this->php_ext}?f=$forum_id\n"; |
166 | 166 | } |
167 | 167 |
@@ -149,7 +149,7 @@ discard block |
||
149 | 149 | */ |
150 | 150 | $this->phpbb_dispatcher->trigger_event('blitze.sitemaker.acp_save_settings'); |
151 | 151 | |
152 | - $this->trigger_error($this->translator->lang('SETTINGS_SAVED') . adm_back_link($this->u_action)); |
|
152 | + $this->trigger_error($this->translator->lang('SETTINGS_SAVED').adm_back_link($this->u_action)); |
|
153 | 153 | } |
154 | 154 | } |
155 | 155 | |
@@ -172,7 +172,7 @@ discard block |
||
172 | 172 | { |
173 | 173 | $style_prefs = (array) json_decode($this->config_text->get('sm_layout_prefs'), true); |
174 | 174 | |
175 | - $result = $this->db->sql_query('SELECT style_id, style_name FROM ' . STYLES_TABLE); |
|
175 | + $result = $this->db->sql_query('SELECT style_id, style_name FROM '.STYLES_TABLE); |
|
176 | 176 | |
177 | 177 | $styles = array(); |
178 | 178 | while ($row = $this->db->sql_fetchrow($result)) |
@@ -239,7 +239,7 @@ discard block |
||
239 | 239 | $path = dirname($path); |
240 | 240 | $name = basename($path); |
241 | 241 | |
242 | - $layouts[$name] = $this->phpbb_root_path . $path . '/'; |
|
242 | + $layouts[$name] = $this->phpbb_root_path.$path.'/'; |
|
243 | 243 | } |
244 | 244 | ksort($layouts); |
245 | 245 | |
@@ -292,7 +292,7 @@ discard block |
||
292 | 292 | $id = $entity->get_menu_id(); |
293 | 293 | $name = $entity->get_menu_name(); |
294 | 294 | $selected = ($id == $this->config['sm_navbar_menu']) ? ' selected="selected"' : ''; |
295 | - $options .= '<option value="' . $id . '"' . $selected . '>' . $name . '</option>'; |
|
295 | + $options .= '<option value="'.$id.'"'.$selected.'>'.$name.'</option>'; |
|
296 | 296 | } |
297 | 297 | |
298 | 298 | return $options; |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | $this->config_path = $config_path; |
40 | 40 | $this->php_ext = $php_ext; |
41 | 41 | |
42 | - $this->config_template = __DIR__ . '/default.config'; |
|
42 | + $this->config_template = __DIR__.'/default.config'; |
|
43 | 43 | } |
44 | 44 | |
45 | 45 | /** |
@@ -51,7 +51,7 @@ discard block |
||
51 | 51 | $config_file = $this->get_config_file(); |
52 | 52 | |
53 | 53 | // credit: http://jafty.com/blog/quick-way-to-check-if-string-exists-in-a-file-with-php/ |
54 | - if (!$this->filesystem->exists($config_file) || !exec('grep ' . escapeshellarg($searcString) . ' ' . $config_file)) |
|
54 | + if (!$this->filesystem->exists($config_file) || !exec('grep '.escapeshellarg($searcString).' '.$config_file)) |
|
55 | 55 | { |
56 | 56 | $this->filesystem->copy($this->config_template, $config_file, true); |
57 | 57 | } |
@@ -123,6 +123,6 @@ discard block |
||
123 | 123 | */ |
124 | 124 | protected function get_config_file() |
125 | 125 | { |
126 | - return $this->config_path . 'config.' . $this->php_ext; |
|
126 | + return $this->config_path.'config.'.$this->php_ext; |
|
127 | 127 | } |
128 | 128 | } |
@@ -59,6 +59,6 @@ |
||
59 | 59 | */ |
60 | 60 | public function get_access_key() |
61 | 61 | { |
62 | - return sha1($this->user->data['user_form_salt'] . 'filemanager'); |
|
62 | + return sha1($this->user->data['user_form_salt'].'filemanager'); |
|
63 | 63 | } |
64 | 64 | } |