Jump to content

Bug? Google Sitemap.xml in Multishop Mode


Recommended Posts

Hi guys,

 

I have a fresh 1.5.2 install with 3 multishops setups:

 

Shop1: MAIN SHOP www.mainshop.com (ALL CATEGORIES)

Shop 2: Latops www.laptops.com (Home Category & LAPTOPS)

Shop 3: iPods www.ipods.com (Home Category & IPODS)

 

WHAT I DID

In the gsitemap module I generated the sitemap.xml files.

 

THE PROBLEM:

The problem is, that the generated sitemaps on the laptop-shop and the ipod-shop still contain ALL categories.

 

THIS WOULD BE RIGHT:

From Seo Point-Of-View this is duplicate content and the sitemap.xml should only contain links to categories and products, which are associated with the specific multishop.

 

Is this a bug or am I seeing something wrong?

 

Kind regards

Rassy

Link to comment
Share on other sites

  • 4 months later...
  • 11 months later...

I've just noticed this too.  If I create a product in shop A only it is duplicated in both Shop A and B's sitemap, and the url is accessible in both shops.  This is even though in the BO it seems correct - the product is only showing in Shop A's catalog and not B's.

Is this right?

Link to comment
Share on other sites

this bug still exist in 1.5,6,1


 


Even if one creates a new product specific to a store , there are multiple entries in "product_lang" table, one each for every store, why this multiple entries are require?


this seems creating issues while generating google sitemap , as there are extra wrong links generated for the product not belongs to that particular store. All products links are generated for all the stores.


  • Like 1
Link to comment
Share on other sites

What I've noticed is that if you delete those double entries in the ps_product_lang table (the ones for the incorrect shop) the sitemap no longer creates the urls for the wrong shop and everything seems to work ok - the product is accessible in the correct shop and returns a 404 in the other shop, which is correct.  I've only tried this on a test site and I've no idea if this can cause other problems.

 

The point is, why is the sitemap module creating urls for both shops even though the product is only created for one shop?  Oh, and the same thing happens with categories.

 

I'm surprised this has not come up before, can anyone shed any light on this one?

Link to comment
Share on other sites

I'm not sure about that.  In the documentation it says this: "When creating a category, either for a specific store or for all the stores in the PrestaShop installation, PrestaShop registers the category for all the stores – it is simply hidden from any store where it has not been set."  So I think it is normal behaviour to create these entries in the database, though I don't know why this is necessary - my site is translated into 15 languages, therefore for each product or category I create there are 15 unnecessary rows, with 1000 products that's a lot!

 

The problem as I see it is with the sitemap module itself - it should not be including urls for a product/category that has been created for one shop only, in the sitemap of all shops.

Link to comment
Share on other sites

i see in 'ps_product_shop' table there are entries of products specific to stores only , so i believe this table has be join in gsitemap.php query.  

 

 

BTW, for a large store with multi language and multi store , those unnecessary entries in  ps_product_lang table will make the database huge, and ultimately effect on speed.

Link to comment
Share on other sites

sitemap bug with multistore setup has been fixed in new version googlesitemap (2.3.6) , can be downloaded from the link available at http://forge.prestashop.com/browse/PNM-1980

 

now query is made on 'ps_product_shop' table , to get products array specific to the stores, but still one question is not answered by anyone , what is the need for multiple entries for inactive products in ps_product_lang table ? 

Link to comment
Share on other sites

×
×
  • Create New...