@@ -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); |
@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | public function get_users_groups() |
41 | 41 | { |
42 | 42 | $sql = 'SELECT group_id |
43 | - FROM ' . USER_GROUP_TABLE . ' |
|
43 | + FROM ' . USER_GROUP_TABLE.' |
|
44 | 44 | WHERE user_id = ' . (int) $this->user->data['user_id']; |
45 | 45 | $result = $this->db->sql_query($sql); |
46 | 46 | |
@@ -83,13 +83,13 @@ discard block |
||
83 | 83 | $sql = $this->_get_group_sql($mode); |
84 | 84 | $result = $this->db->sql_query($sql); |
85 | 85 | |
86 | - $options = '<option value="0">' . $this->translator->lang('ALL') . '</option>'; |
|
86 | + $options = '<option value="0">'.$this->translator->lang('ALL').'</option>'; |
|
87 | 87 | while ($row = $this->db->sql_fetchrow($result)) |
88 | 88 | { |
89 | 89 | $group_name = $this->_get_group_name($row); |
90 | 90 | $group_class = $this->_get_group_class($row['group_type']); |
91 | 91 | $selected_option = $this->_get_selected_option($row['group_id'], $selected); |
92 | - $options .= '<option' . $group_class . ' value="' . $row['group_id'] . '"' . $selected_option . '>' . $group_name . '</option>'; |
|
92 | + $options .= '<option'.$group_class.' value="'.$row['group_id'].'"'.$selected_option.'>'.$group_name.'</option>'; |
|
93 | 93 | } |
94 | 94 | $this->db->sql_freeresult($result); |
95 | 95 | |
@@ -103,8 +103,8 @@ discard block |
||
103 | 103 | private function _get_group_sql($mode) |
104 | 104 | { |
105 | 105 | return 'SELECT group_id, group_name, group_type |
106 | - FROM ' . GROUPS_TABLE . |
|
107 | - (($mode === 'special') ? ' WHERE group_type = ' . GROUP_SPECIAL : '') . ' |
|
106 | + FROM ' . GROUPS_TABLE. |
|
107 | + (($mode === 'special') ? ' WHERE group_type = '.GROUP_SPECIAL : '').' |
|
108 | 108 | ORDER BY group_type DESC, group_name ASC'; |
109 | 109 | } |
110 | 110 | |
@@ -114,7 +114,7 @@ discard block |
||
114 | 114 | */ |
115 | 115 | private function _get_group_name(array $row) |
116 | 116 | { |
117 | - return ($row['group_type'] == GROUP_SPECIAL) ? $this->translator->lang('G_' . $row['group_name']) : ucfirst($row['group_name']); |
|
117 | + return ($row['group_type'] == GROUP_SPECIAL) ? $this->translator->lang('G_'.$row['group_name']) : ucfirst($row['group_name']); |
|
118 | 118 | } |
119 | 119 | |
120 | 120 | /** |
@@ -69,7 +69,7 @@ discard block |
||
69 | 69 | $content = $this->request->variable('content', '', true); |
70 | 70 | $cblocks = $this->get_custom_blocks(); |
71 | 71 | |
72 | - $sql_data = $this->get_default_fields($block_id); |
|
72 | + $sql_data = $this->get_default_fields($block_id); |
|
73 | 73 | $sql_data['block_content'] = $content; |
74 | 74 | |
75 | 75 | generate_text_for_storage($sql_data['block_content'], $sql_data['bbcode_uid'], $sql_data['bbcode_bitfield'], $sql_data['bbcode_options'], true, true, true); |
@@ -130,11 +130,11 @@ discard block |
||
130 | 130 | { |
131 | 131 | if (!$block_exists) |
132 | 132 | { |
133 | - $sql = 'INSERT INTO ' . $this->cblocks_table . ' ' . $this->db->sql_build_array('INSERT', $sql_data); |
|
133 | + $sql = 'INSERT INTO '.$this->cblocks_table.' '.$this->db->sql_build_array('INSERT', $sql_data); |
|
134 | 134 | } |
135 | 135 | else |
136 | 136 | { |
137 | - $sql = 'UPDATE ' . $this->cblocks_table . ' SET ' . $this->db->sql_build_array('UPDATE', $sql_data) . ' WHERE block_id = ' . (int) $sql_data['block_id']; |
|
137 | + $sql = 'UPDATE '.$this->cblocks_table.' SET '.$this->db->sql_build_array('UPDATE', $sql_data).' WHERE block_id = '.(int) $sql_data['block_id']; |
|
138 | 138 | } |
139 | 139 | $this->db->sql_query($sql); |
140 | 140 | $this->cache->destroy('pt_cblocks'); |
@@ -151,7 +151,7 @@ discard block |
||
151 | 151 | if ($edit_mode !== false) |
152 | 152 | { |
153 | 153 | decode_message($cblock['block_content'], $cblock['bbcode_uid']); |
154 | - $content = '<div id="block-editor-' . $cblock['block_id'] . '" class="editable editable-block" data-service="blitze.sitemaker.block.custom" data-method="edit" data-raw="' . $cblock['block_content'] . '">' . $content . '</div>'; |
|
154 | + $content = '<div id="block-editor-'.$cblock['block_id'].'" class="editable editable-block" data-service="blitze.sitemaker.block.custom" data-method="edit" data-raw="'.$cblock['block_content'].'">'.$content.'</div>'; |
|
155 | 155 | } |
156 | 156 | } |
157 | 157 |
@@ -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 |
@@ -138,7 +138,7 @@ |
||
138 | 138 | $this->ptemplate->assign_block_vars('postrow.attachment', array( |
139 | 139 | 'DISPLAY_ATTACHMENT' => $attachment, |
140 | 140 | 'EXTENSION_GROUP' => $extensions[$row['extension']]['group_name'], |
141 | - 'U_VIEWTOPIC' => append_sid("{$this->phpbb_root_path}viewtopic.{$this->php_ext}", "t=$topic_id&p=$post_id") . '#p' . $post_id, |
|
141 | + 'U_VIEWTOPIC' => append_sid("{$this->phpbb_root_path}viewtopic.{$this->php_ext}", "t=$topic_id&p=$post_id").'#p'.$post_id, |
|
142 | 142 | )); |
143 | 143 | } |
144 | 144 | } |
@@ -71,9 +71,9 @@ |
||
71 | 71 | $this->ptemplate->assign_vars(array( |
72 | 72 | 'S_SHOW_HIDE_ME' => ($settings['show_hide_me']) ? true : false, |
73 | 73 | 'S_AUTOLOGIN_ENABLED' => ($settings['allow_autologin']) ? true : false, |
74 | - 'S_LOGIN_ACTION' => append_sid("{$this->phpbb_root_path}ucp." . $this->php_ext, 'mode=login'), |
|
75 | - 'U_REGISTER' => append_sid("{$this->phpbb_root_path}ucp." . $this->php_ext, 'mode=register'), |
|
76 | - 'U_SEND_PASSWORD' => append_sid("{$this->phpbb_root_path}ucp." . $this->php_ext, 'mode=sendpassword'), |
|
74 | + 'S_LOGIN_ACTION' => append_sid("{$this->phpbb_root_path}ucp.".$this->php_ext, 'mode=login'), |
|
75 | + 'U_REGISTER' => append_sid("{$this->phpbb_root_path}ucp.".$this->php_ext, 'mode=register'), |
|
76 | + 'U_SEND_PASSWORD' => append_sid("{$this->phpbb_root_path}ucp.".$this->php_ext, 'mode=sendpassword'), |
|
77 | 77 | 'U_REDIRECT' => reapply_sid(ltrim(rtrim(build_url(array('edit_mode')), '?'), './../')) |
78 | 78 | )); |
79 | 79 |
@@ -99,7 +99,7 @@ discard block |
||
99 | 99 | |
100 | 100 | $this->ptemplate->assign_block_vars('topicrow', array( |
101 | 101 | 'TOPIC_TITLE' => censor_text($row['topic_title']), |
102 | - 'U_VIEWTOPIC' => append_sid($this->phpbb_root_path . 'viewtopic.' . $this->php_ext, "f=$forum_id&t=$topic_id"), |
|
102 | + 'U_VIEWTOPIC' => append_sid($this->phpbb_root_path.'viewtopic.'.$this->php_ext, "f=$forum_id&t=$topic_id"), |
|
103 | 103 | )); |
104 | 104 | unset($topic_data[$i]); |
105 | 105 | } |
@@ -140,7 +140,7 @@ discard block |
||
140 | 140 | { |
141 | 141 | return array( |
142 | 142 | 'WHERE' => array( |
143 | - 't.topic_last_post_time > ' . $this->user->data['user_lastvisit'], |
|
143 | + 't.topic_last_post_time > '.$this->user->data['user_lastvisit'], |
|
144 | 144 | 't.topic_moved_id = 0', |
145 | 145 | ), |
146 | 146 | ); |
@@ -156,7 +156,7 @@ discard block |
||
156 | 156 | POSTS_TABLE => 'p', |
157 | 157 | ), |
158 | 158 | 'WHERE' => array( |
159 | - 't.topic_id = p.topic_id AND p.post_time > ' . $this->user->data['user_lastvisit'], |
|
159 | + 't.topic_id = p.topic_id AND p.post_time > '.$this->user->data['user_lastvisit'], |
|
160 | 160 | ), |
161 | 161 | ); |
162 | 162 | } |
@@ -68,7 +68,7 @@ discard block |
||
68 | 68 | |
69 | 69 | if (!empty($data['.'][0]['TOTAL_USERS_ONLINE'])) |
70 | 70 | { |
71 | - $l_online_users = $data['.'][0]['TOTAL_USERS_ONLINE']; |
|
71 | + $l_online_users = $data['.'][0]['TOTAL_USERS_ONLINE']; |
|
72 | 72 | $online_userlist = $data['.'][0]['LOGGED_IN_USER_LIST']; |
73 | 73 | $l_online_record = $data['.'][0]['RECORD_USERS']; |
74 | 74 | } |
@@ -105,6 +105,6 @@ discard block |
||
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 | } |