Jump to content

google sitemap manually generate url incorrect


Recommended Posts

Hi everyone,

I am using ps 1.5 and google sitemap version is 2.2.7,Route to products like:{id}--.html.

when i use manually generation sitemap url and find the product url was incorrect(the url like: www.domain.com/{category}/{id}-{rewrite}.html ). but use automatically generation was correct{url: www.domain.com/{id}--.html}.

than i find one place was strange, classes/Link.php when use manually genration url will has param $params['category'] and automatically without. it come from :

if ($dispatcher->hasKeyword('product_rule', $id_lang, 'category'))

$params['category'] = Tools::str2url($product->category);

 

and the incorrect url including rewrite wording, classes/Dispatcher.php

if (defined('_PS_ADMIN_DIR_'))

{

$this->front_controller = self::FC_ADMIN;

$this->controller_not_found = 'adminnotfound';

$this->default_controller = 'adminhome';

$this->use_routes = false;

}

here set the use_routes=false.

 

anyone have a different opinion?

how to fix this issue more easily?

 

best regards.

Link to comment
Share on other sites

  • 1 month later...
×
×
  • Create New...