| |
| |
|
|
|
|
| |
|
| |
|
| :: |
| Author |
Message |
janmyszkier
Joined: 12 Oct 2007 Posts: 42 Location: Wroclaw, Poland.
|
|
| Back to top |
|
 |
|
 |
dcz Administrateur - Site Admin

Joined: 28 Apr 2006 Posts: 14131
|
Posted: Tue Apr 22, 2008 12:28 pm Post subject: Re: 3.0.1 bug ? |
|
|
Did you udpate or is it a fresh install ?
Because the bug does not occur on the demo server : http://phpbb3.phpbb-seo.net/sub-forum/
Make sure you have the proper code for the topic_generate_pagination() function in includes/functions_display.php, eg :
| Code: | /**
* Generate topic pagination
*/
function topic_generate_pagination($replies, $url)
{
global $config, $user;
// www.phpBB-SEO.com SEO TOOLKIT BEGIN
global $phpbb_seo, $phpEx;
// www.phpBB-SEO.com SEO TOOLKIT END
// Make sure $per_page is a valid value
$per_page = ($config['posts_per_page'] <= 0) ? 1 : $config['posts_per_page'];
if (($replies + 1) > $per_page)
{
$total_pages = ceil(($replies + 1) / $per_page);
$pagination = '';
$times = 1;
for ($j = 0; $j < $replies + 1; $j += $per_page)
{
$pagination .= '<a href="' . $url . '&start=' . $j . '">' . $times . '</a>';
if ($times == 1 && $total_pages > 5)
{
$pagination .= ' ... ';
// Display the last three pages
$times = $total_pages - 3;
$j += ($total_pages - 4) * $per_page;
}
else if ($times < $total_pages)
{
$pagination .= '<span class="page-sep">' . $user->lang['COMMA_SEPARATOR'] . '</span>';
}
$times++;
}
// www.phpBB-SEO.com SEO TOOLKIT BEGIN
if (!empty($phpbb_seo->seo_opt['url_rewrite'])) {
static $pagin_find = array();
static $pagin_replace = array();
if (empty($pagin_find)) {
$pagin_find = array( '`(\.(?!' . $phpEx . ')[a-z0-9]+)([\w\#$%&~\-;:=,?@+]*)&start=([0-9]+)`i', '`/([\w\#$%&~\-;:=,?@+]*)&start=([0-9]+)`i' );
$pagin_replace = array( $phpbb_seo->seo_delim['start'] . '\\3\\1\\2', '/' . $phpbb_seo->seo_static['pagination'] . '\\2' . $phpbb_seo->seo_ext['pagination'] .'\\1' );
}
$pagination = str_replace( '&start=0', '', $pagination );
$pagination = preg_replace( $pagin_find, $pagin_replace, $pagination );
}
// www.phpBB-SEO.com SEO TOOLKIT END
}
else
{
$pagination = '';
}
return $pagination;
} |
It seems as well, and most likely means you updated, that your .htaccess is not up to date, forum pagination is not working even though the url are correct.
++ |
_________________ Useful links :
SEO Forum || SEO Directory || SEO phpBB || SEO phpBB3 || Search
____________________
Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Référencement phpBB3 || Recherche |
|
| Back to top |
|
 |
janmyszkier
Joined: 12 Oct 2007 Posts: 42 Location: Wroclaw, Poland.
|
Posted: Tue Apr 22, 2008 1:07 pm Post subject: Re: 3.0.1 bug ? |
|
|
i did update, updated htaccess with the new one as specified on the forum
will check the function about pagination in a minute, will just fetch some tea ^_^
EDIT: works like a charm, thank you! |
|
|
| Back to top |
|
 |
|
|
|
|
| |
|
|
|
|
| |
|
|
|
|
| |