So this was found in the french board, it will allow the last message mxBB module to output mod rewritten URL.
For the phpBB SEO Advanced mod rewrite just apply all of the following code, for the mixed, just aply the code concerning $seo_forum_name and to not copy the line (or the part of the line) with $seo_topic_name, for Simple mod rewrite, well it's already working so ... :
Open:
- Code: Select all
modules/mx_last_msg/mx_last_msg.php
Find:
- Code: Select all
for($row_count = 0; $row_count < count($postrow); $row_count++)
{
$row_color = ( !($row_count%2) ) ? $theme['td_color1'] : $theme['td_color2'];
$row_class = ( !($row_count%2) ) ? $theme['td_class1'] : $theme['td_class2'];
$message = $postrow[$row_count]['topic_title'];
After add :
- Code: Select all
// phpBB-SEO.com SEO TOOLKIT BEGIN
$seo_forum_name = $postrow[$row_count]['forum_name'];
$seo_topic_name = $message;
// phpBB-SEO.com SEO TOOLKIT END
Find:
- Code: Select all
$url = append_sid( PHPBB_URL . 'viewtopic.php?t='.$postrow[$row_count]['topic_id'].'#'.$postrow[$row_count]['topic_last_post_id']);
Replace with :
- Code: Select all
$url = append_sid( PHPBB_URL . 'viewtopic.php?t='.$postrow[$row_count]['topic_id']);
Find:
- Code: Select all
$template->pparse("body_last_msg");
Before add :
- Code: Select all
// phpBB-SEO.com SEO TOOLKIT BEGIN
$seo_forum_name = $seo_topic_name = FALSE;
// phpBB-SEO.com SEO TOOLKIT END
And then, if you don't want the link to the last post to be rewritten, in order not to outpu any duplicate, please do the following also in the same file:
Find:
- Code: Select all
$url = append_sid( PHPBB_URL . 'viewtopic.php?t='.$postrow[$row_count]['topic_id'].'#'.$postrow[$row_count]['topic_last_post_id']);
After add :
- Code: Select all
// phpBB-SEO.com SEO TOOLKIT BEGIN
$seo_topic_name = FALSE;
// phpBB-SEO.com SEO TOOLKIT END
Enjoy

English |
French
News


