| @@ -55,9 +55,9 @@ discard block | ||
| 55 | 55 |  	{ | 
| 56 | 56 | if ($full) | 
| 57 | 57 |  		{ | 
| 58 | - return generate_board_url() . '/' . $this->title_to_url($forum_name) . '-f' . $forum_id . '/' . $this->title_to_url($topic_title) . '-t' . $topic_id . ($start ? '-s' . $start : '') . '.html'; | |
| 58 | + return generate_board_url().'/'.$this->title_to_url($forum_name).'-f'.$forum_id.'/'.$this->title_to_url($topic_title).'-t'.$topic_id.($start ? '-s'.$start : '').'.html'; | |
| 59 | 59 | } | 
| 60 | - return $this->phpbb_root_path . $this->title_to_url($forum_name) . '-f' . $forum_id . '/' . $this->title_to_url($topic_title) . '-t' . $topic_id . ($start ? '-s' . $start : '') . '.html'; | |
| 60 | + return $this->phpbb_root_path.$this->title_to_url($forum_name).'-f'.$forum_id.'/'.$this->title_to_url($topic_title).'-t'.$topic_id.($start ? '-s'.$start : '').'.html'; | |
| 61 | 61 | } | 
| 62 | 62 | |
| 63 | 63 | /** | 
| @@ -74,9 +74,9 @@ discard block | ||
| 74 | 74 |  	{ | 
| 75 | 75 | if ($full) | 
| 76 | 76 |  		{ | 
| 77 | - return generate_board_url() . '/' . $this->title_to_url($forum_name) . '-f' . $forum_id . '/' . ($start ? 'index-s' . $start . '.html' : ''); | |
| 77 | + return generate_board_url().'/'.$this->title_to_url($forum_name).'-f'.$forum_id.'/'.($start ? 'index-s'.$start.'.html' : ''); | |
| 78 | 78 | } | 
| 79 | - return $this->phpbb_root_path . $this->title_to_url($forum_name) . '-f' . $forum_id . '/' . ($start ? 'index-s' . $start . '.html' : ''); | |
| 79 | + return $this->phpbb_root_path.$this->title_to_url($forum_name).'-f'.$forum_id.'/'.($start ? 'index-s'.$start.'.html' : ''); | |
| 80 | 80 | } | 
| 81 | 81 | |
| 82 | 82 | /** | 
| @@ -95,12 +95,12 @@ discard block | ||
| 95 | 95 |  		{ | 
| 96 | 96 | for ($j = 0; $j < $replies + 1; $j += $per_page) | 
| 97 | 97 |  			{ | 
| 98 | - $last_post_link = $url . '-s' . $j . '.html'; | |
| 98 | + $last_post_link = $url.'-s'.$j.'.html'; | |
| 99 | 99 | } | 
| 100 | 100 | } | 
| 101 | 101 | else | 
| 102 | 102 |  		{ | 
| 103 | - $last_post_link = $url . '.html'; | |
| 103 | + $last_post_link = $url.'.html'; | |
| 104 | 104 | } | 
| 105 | 105 | return $last_post_link; | 
| 106 | 106 | } | 
| @@ -139,9 +139,9 @@ discard block | ||
| 139 | 139 |  	{ | 
| 140 | 140 |  		if (!$this->auth->acl_get('m_approve', $forum_id)) | 
| 141 | 141 |  		{ | 
| 142 | - return (int) $data[$mode . '_approved']; | |
| 142 | + return (int) $data[$mode.'_approved']; | |
| 143 | 143 | } | 
| 144 | 144 | |
| 145 | - return (int) $data[$mode . '_approved'] + (int) $data[$mode . '_unapproved'] + (int) $data[$mode . '_softdeleted']; | |
| 145 | + return (int) $data[$mode.'_approved'] + (int) $data[$mode.'_unapproved'] + (int) $data[$mode.'_softdeleted']; | |
| 146 | 146 | } | 
| 147 | 147 | } | 
| @@ -63,14 +63,14 @@ discard block | ||
| 63 | 63 | return; | 
| 64 | 64 | } | 
| 65 | 65 | |
| 66 | - $url_data =$event['url_data'] ; | |
| 66 | + $url_data = $event['url_data']; | |
| 67 | 67 | |
| 68 | 68 | foreach ($url_data as $id => $data) | 
| 69 | 69 |  		{ | 
| 70 | 70 | $row = $data['row']; | 
| 71 | 71 | if (isset($row['topic_id'])) | 
| 72 | 72 |  			{ | 
| 73 | - $url_data[$id]['url'] = $this->base->generate_topic_link($row['forum_id'], $row['forum_name'], $row['topic_id'], $row['topic_title'], $data['start'], true); | |
| 73 | + $url_data[$id]['url'] = $this->base->generate_topic_link($row['forum_id'], $row['forum_name'], $row['topic_id'], $row['topic_title'], $data['start'], true); | |
| 74 | 74 | } | 
| 75 | 75 | else if (isset($row['forum_id'])) | 
| 76 | 76 |  			{ | 
| @@ -96,10 +96,10 @@ discard block | ||
| 96 | 96 | $this->topic_id = $event['row']['topic_id']; | 
| 97 | 97 | |
| 98 | 98 | $topic_row = $event['topic_row']; | 
| 99 | - $u_view_topic= $this->base->generate_topic_link($this->forum_id, $this->forum_title, $this->topic_id, $this->topic_title); | |
| 99 | + $u_view_topic = $this->base->generate_topic_link($this->forum_id, $this->forum_title, $this->topic_id, $this->topic_title); | |
| 100 | 100 | $topic_row['U_VIEW_TOPIC'] = append_sid($u_view_topic); | 
| 101 | 101 | $topic_row['U_VIEW_FORUM'] = append_sid($this->base->generate_forum_link($this->forum_id, $this->forum_title)); | 
| 102 | - $topic_row['U_LAST_POST'] = append_sid($this->base->generate_lastpost_link($topic_row['TOPIC_REPLIES'], $u_view_topic) . '#p' . $event['row']['topic_last_post_id']); | |
| 102 | + $topic_row['U_LAST_POST'] = append_sid($this->base->generate_lastpost_link($topic_row['TOPIC_REPLIES'], $u_view_topic).'#p'.$event['row']['topic_last_post_id']); | |
| 103 | 103 | $event['topic_row'] = $topic_row; | 
| 104 | 104 | } | 
| 105 | 105 | |
| @@ -130,7 +130,7 @@ discard block | ||
| 130 | 130 | $tpl_ary = $event['tpl_ary']; | 
| 131 | 131 |  		$replies = $this->base->get_count('topic_posts', $event['row'], $event['row']['forum_id']) - 1; | 
| 132 | 132 | $u_view_topic = $this->base->generate_topic_link($event['row']['forum_id'], $event['row']['forum_name'], $event['row']['topic_id'], $event['row']['topic_title']); | 
| 133 | - $tpl_ary['U_TOPIC'] = append_sid($this->base->generate_lastpost_link($replies, $u_view_topic) . '#p' . $event['row']['topic_last_post_id']); | |
| 133 | + $tpl_ary['U_TOPIC'] = append_sid($this->base->generate_lastpost_link($replies, $u_view_topic).'#p'.$event['row']['topic_last_post_id']); | |
| 134 | 134 | $event['tpl_ary'] = $tpl_ary; | 
| 135 | 135 | } | 
| 136 | 136 | } | 
| @@ -70,7 +70,7 @@ discard block | ||
| 70 | 70 | 'core.display_forums_modify_template_vars' => 'display_forums_modify_template_vars', | 
| 71 | 71 | 'core.display_forums_modify_forum_rows' => 'display_forums_modify_forum_rows', | 
| 72 | 72 | 'core.generate_forum_nav' => 'generate_forum_nav', | 
| 73 | - 'core.make_jumpbox_modify_tpl_ary' => 'make_jumpbox_modify_tpl_ary', // Not in phpBB | |
| 73 | + 'core.make_jumpbox_modify_tpl_ary' => 'make_jumpbox_modify_tpl_ary', // Not in phpBB | |
| 74 | 74 | 'core.pagination_generate_page_link' => 'pagination_generate_page_link', | 
| 75 | 75 | 'core.search_modify_tpl_ary' => 'search_modify_tpl_ary', | 
| 76 | 76 | 'core.viewforum_modify_topicrow' => 'viewforum_modify_topicrow', | 
| @@ -91,9 +91,9 @@ discard block | ||
| 91 | 91 | */ | 
| 92 | 92 | public function append_sid($event) | 
| 93 | 93 |  	{ | 
| 94 | -		if (preg_match('#./../viewtopic.' . $this->php_ext  . '#', $event['url'])) | |
| 94 | +		if (preg_match('#./../viewtopic.'.$this->php_ext.'#', $event['url'])) | |
| 95 | 95 |  		{ | 
| 96 | - $url = $this->phpbb_root_path . 'viewtopic.' . $this->php_ext ; | |
| 96 | + $url = $this->phpbb_root_path.'viewtopic.'.$this->php_ext; | |
| 97 | 97 | $event['url'] = $url; | 
| 98 | 98 | } | 
| 99 | 99 | } | 
| @@ -128,9 +128,9 @@ discard block | ||
| 128 | 128 | $forum_rows = $event['forum_rows']; | 
| 129 | 129 | if ($event['row']['forum_last_post_time'] == $forum_rows[$event['parent_id']]['forum_last_post_time']) | 
| 130 | 130 |  		{ | 
| 131 | - $forum_rows[$event['parent_id']]['forum_name_last_post'] =$event['row']['forum_name']; | |
| 132 | - $forum_rows[$event['parent_id']]['topic_id_last_post'] =$event['row']['topic_id']; | |
| 133 | - $forum_rows[$event['parent_id']]['topic_title_last_post'] =$event['row']['topic_title']; | |
| 131 | + $forum_rows[$event['parent_id']]['forum_name_last_post'] = $event['row']['forum_name']; | |
| 132 | + $forum_rows[$event['parent_id']]['topic_id_last_post'] = $event['row']['topic_id']; | |
| 133 | + $forum_rows[$event['parent_id']]['topic_title_last_post'] = $event['row']['topic_title']; | |
| 134 | 134 | $event['forum_rows'] = $forum_rows; | 
| 135 | 135 | } | 
| 136 | 136 | } | 
| @@ -159,12 +159,12 @@ discard block | ||
| 159 | 159 | |
| 160 | 160 | // Update the image source in forums | 
| 161 | 161 | $img = $this->path_helper->update_web_root_path($forum_row['FORUM_IMAGE_SRC']); | 
| 162 | -		$forum_row['FORUM_IMAGE'] = preg_replace('#img src=\"(.*)\" alt#', 'img src="' . $img . '" alt', $forum_row['FORUM_IMAGE']); | |
| 162 | +		$forum_row['FORUM_IMAGE'] = preg_replace('#img src=\"(.*)\" alt#', 'img src="'.$img.'" alt', $forum_row['FORUM_IMAGE']); | |
| 163 | 163 | |
| 164 | 164 | // Rewrite links to topics, posts and forums | 
| 165 | 165 |  		$replies = $this->base->get_count('topic_posts', $event['row'], $event['row']['forum_id']) - 1; | 
| 166 | 166 | $url = $this->base->generate_topic_link($event['row']['forum_id_last_post'], $event['row']['forum_name_last_post'], $event['row']['topic_id_last_post'], $event['row']['topic_title_last_post']); | 
| 167 | - $forum_row['U_LAST_POST'] = append_sid($this->base->generate_lastpost_link($replies, $url) . '#p' . $event['row']['forum_last_post_id']); | |
| 167 | + $forum_row['U_LAST_POST'] = append_sid($this->base->generate_lastpost_link($replies, $url).'#p'.$event['row']['forum_last_post_id']); | |
| 168 | 168 | $forum_row['U_VIEWFORUM'] = append_sid($this->base->generate_forum_link($forum_row['FORUM_ID'], $forum_row['FORUM_NAME'])); | 
| 169 | 169 | |
| 170 | 170 | $event['subforums_row'] = $subforums_row; | 
| @@ -186,7 +186,7 @@ discard block | ||
| 186 | 186 | |
| 187 | 187 | foreach ($navlinks_parents as $id => $data) | 
| 188 | 188 |  		{ | 
| 189 | - $navlinks_parents[$id]['U_VIEW_FORUM'] = append_sid($this->base->generate_forum_link($data['FORUM_ID'] , $data['FORUM_NAME'])); | |
| 189 | + $navlinks_parents[$id]['U_VIEW_FORUM'] = append_sid($this->base->generate_forum_link($data['FORUM_ID'], $data['FORUM_NAME'])); | |
| 190 | 190 | } | 
| 191 | 191 | |
| 192 | 192 | $navlinks['U_VIEW_FORUM'] = append_sid($this->base->generate_forum_link($forum_data['forum_id'], $forum_data['forum_name'])); | 
| @@ -201,7 +201,7 @@ discard block | ||
| 201 | 201 | $row = $event['row']; | 
| 202 | 202 | foreach ($tpl_ary as $id => $data) | 
| 203 | 203 |  		{ | 
| 204 | - $tpl_ary[$id]['LINK'] = append_sid($this->base->generate_forum_link($row['forum_id'], $row['forum_name'])); | |
| 204 | + $tpl_ary[$id]['LINK'] = append_sid($this->base->generate_forum_link($row['forum_id'], $row['forum_name'])); | |
| 205 | 205 | } | 
| 206 | 206 | |
| 207 | 207 | $event['tpl_ary'] = $tpl_ary; | 
| @@ -248,7 +248,7 @@ discard block | ||
| 248 | 248 | $u_view_topic = $this->base->generate_topic_link($event['row']['forum_id'], $event['row']['forum_name'], $event['row']['topic_id'], $event['row']['topic_title']); | 
| 249 | 249 | |
| 250 | 250 | $tpl_ary = $event['tpl_ary']; | 
| 251 | - $tpl_ary['U_LAST_POST'] = append_sid($this->base->generate_lastpost_link($replies, $u_view_topic) . '#p' . $event['row']['topic_last_post_id']); | |
| 251 | + $tpl_ary['U_LAST_POST'] = append_sid($this->base->generate_lastpost_link($replies, $u_view_topic).'#p'.$event['row']['topic_last_post_id']); | |
| 252 | 252 | $tpl_ary['U_VIEW_TOPIC'] = append_sid($u_view_topic); | 
| 253 | 253 | $tpl_ary['U_VIEW_FORUM'] = append_sid($this->base->generate_forum_link($event['row']['forum_id'], $event['row']['forum_name'])); | 
| 254 | 254 | |
| @@ -273,7 +273,7 @@ discard block | ||
| 273 | 273 | $u_view_topic = $this->base->generate_topic_link($this->forum_id, $this->forum_title, $this->topic_id, $this->topic_title); | 
| 274 | 274 | $topic_row['U_VIEW_TOPIC'] = append_sid($u_view_topic); | 
| 275 | 275 | $topic_row['U_VIEW_FORUM'] = append_sid($this->base->generate_forum_link($this->forum_id, $this->forum_title)); | 
| 276 | - $topic_row['U_LAST_POST'] = append_sid($this->base->generate_lastpost_link($event['topic_row']['REPLIES'], $u_view_topic) . '#p' . $event['row']['topic_last_post_id']); | |
| 276 | + $topic_row['U_LAST_POST'] = append_sid($this->base->generate_lastpost_link($event['topic_row']['REPLIES'], $u_view_topic).'#p'.$event['row']['topic_last_post_id']); | |
| 277 | 277 | |
| 278 | 278 | $event['topic_row'] = $topic_row; | 
| 279 | 279 | } | 
| @@ -305,8 +305,8 @@ discard block | ||
| 305 | 305 |  	{ | 
| 306 | 306 | $data = $event['topic_data']; | 
| 307 | 307 | $this->template->assign_vars(array( | 
| 308 | - 'U_VIEW_TOPIC' => append_sid($this->base->generate_topic_link($event['forum_id'] , $data['forum_name'], $event['topic_id'], $data['topic_title'], $event['start'])), | |
| 309 | - 'U_VIEW_FORUM' => append_sid($this->base->generate_forum_link($event['forum_id'] , $data['forum_name'])), | |
| 308 | + 'U_VIEW_TOPIC' => append_sid($this->base->generate_topic_link($event['forum_id'], $data['forum_name'], $event['topic_id'], $data['topic_title'], $event['start'])), | |
| 309 | + 'U_VIEW_FORUM' => append_sid($this->base->generate_forum_link($event['forum_id'], $data['forum_name'])), | |
| 310 | 310 | )); | 
| 311 | 311 | } | 
| 312 | 312 | |
| @@ -353,7 +353,7 @@ discard block | ||
| 353 | 353 | $row = $event['post_row']; | 
| 354 | 354 |  		$start = $this->request->variable('start', 0); | 
| 355 | 355 | $data = $event['topic_data']; | 
| 356 | - $row['U_MINI_POST'] = append_sid($this->base->generate_topic_link($data['forum_id'], $data['forum_name'], $data['topic_id'], $data['topic_title'], $start) . '#p' . $event['row']['post_id']); | |
| 356 | + $row['U_MINI_POST'] = append_sid($this->base->generate_topic_link($data['forum_id'], $data['forum_name'], $data['topic_id'], $data['topic_title'], $start).'#p'.$event['row']['post_id']); | |
| 357 | 357 | $event['post_row'] = $row; | 
| 358 | 358 | } | 
| 359 | 359 | } |