[phpBB3] URL rewriting and Sitemaps

Magic SEO URLs for phpBB.
nicolasg
Posts: 4
Joined: Fri May 27, 2016 1:19 am

[phpBB3] URL rewriting and Sitemaps

Postby nicolasg » Fri May 27, 2016 2:32 am

I have a problem, no rewrite url in sitemap :(

I use this module :
https://www.phpbb.com/customise/db/exte ... o_sitemap/

Do you have any solution please ? or other extension sitemap compatible with the module inveo ?

Thank ;)

inveo
Inveo Support
Posts: 1276
Joined: Sat Feb 02, 2008 12:07 pm
Contact:

Re: [phpBB3] URL rewriting and Sitemaps

Postby inveo » Fri May 27, 2016 3:29 am

To add support of URL rewriting to this Sitemaps extension, please:

1) open /ext/shredder/sitemap/core.php file:

Find:

Code: Select all

class core


Replace with:

Code: Select all

define('MSU_LOAD_LIB_ONLY_BB', true);
include(dirname(dirname(dirname(dirname(__FILE__)))).'/includes/magic_seo_url.php');

class core


Find:

Code: Select all

$f_xml .= '<loc>'.$loc.'</loc>'."\r\n";


Replace with:

Code: Select all

$f_xml .= '<loc>'.msuTransformUrlBb($loc).'</loc>'."\r\n";


Save and upload to your FTP and all is done :-)

nicolasg
Posts: 4
Joined: Fri May 27, 2016 1:19 am

Re: [phpBB3] URL rewriting and Sitemaps

Postby nicolasg » Fri May 27, 2016 3:40 am

Very good :) ;)

Binano
Posts: 13
Joined: Fri May 27, 2016 10:05 am

Re: [phpBB3] URL rewriting and Sitemaps

Postby Binano » Wed Oct 12, 2016 12:28 pm

Hello,

There's a new version. Can you help me please ?
https://www.phpbb.com/customise/db/download/128081

inveo
Inveo Support
Posts: 1276
Joined: Sat Feb 02, 2008 12:07 pm
Contact:

Re: [phpBB3] URL rewriting and Sitemaps

Postby inveo » Thu Oct 13, 2016 4:50 am

To add support of URL rewriting to the the recent version of this Sitemaps extension, please:

Open /ext/shredder/sitemap/core.php file:

Find:

Code: Select all

class core


Replace with:

Code: Select all

define('MSU_LOAD_LIB_ONLY_BB', true);
include(dirname(dirname(dirname(dirname(__FILE__)))).'/includes/magic_seo_url.php');

class core


Find:

Code: Select all

$this->appender->append($f_url, (int) max(array_merge($glob, $ann, $times)), $this->config['sitemap_seo_freq_f'], $this->config['sitemap_seo_prior_f']);


Replace with:

Code: Select all

$this->appender->append(msuTransformUrlBb($f_url), (int) max(array_merge($glob, $ann, $times)), $this->config['sitemap_seo_freq_f'], $this->config['sitemap_seo_prior_f']);


Find:

Code: Select all

$this->appender->append($t_url, max($times), $this->frequency[$t_type], $this->priority[$t_type]);


Replace with:

Code: Select all

$this->appender->append(msuTransformUrlBb($t_url), max($times), $this->frequency[$t_type], $this->priority[$t_type]);


Save and upload to your FTP and all is done :-)

Binano
Posts: 13
Joined: Fri May 27, 2016 10:05 am

Re: [phpBB3] URL rewriting and Sitemaps

Postby Binano » Thu Oct 13, 2016 6:03 am

Good job ! 8-)