Yes, I understand, but the patch is essentially the same except for the code placement.
Recall that the append_sid method refers to phpbb_seo, a global class instance that does the remapping. It maintains a table that maps topic ids to topic titles; your code additions cache these topic / topic id entries in the global so they'll be properly mapped.
I've not tested the changes below, but I believe they're correct. Open similar_topics.php and find:
- Code: Select all
if ( !defined('IN_PHPBB') )
{
die("Hacking attempt");
}
Add after:
- Code: Select all
// www.phpBB-SEO.com SEO TOOLKIT BEGIN
global $phpbb_seo;
// www.phpBB-SEO.com SEO TOOLKIT END
Find:
- Code: Select all
//
// Censor topic title
//
if ( count($orig_word) )
{
$similar['topic_title'] = @preg_replace($orig_word, $replacement_word, $similar['topic_title']);
}
Add after:
- Code: Select all
// www.phpBB-SEO.com SEO TOOLKIT BEGIN
$phpbb_seo->seo_url['topic'][$similar['topic_id']] = $phpbb_seo->format_url($similar['topic_title']);
// www.phpBB-SEO.com SEO TOOLKIT END