404 when switching between stores when in a category on magento

There are 5 store views on my magento website. When we are in a product in English and select French, it correctly redirects and displays the product in French. But when it comes to categories, it doesn't work at all.

I am in the category with the address http://myweb.com/en/body-care , if I turn to the Spanish look, it does not redirect to the url "../cuidado-del-cuerpo" it just goes to http: // myweb.com/es/body-care and shows a 404 error (it changes the 'en' for 'es' but does not change the last part of the url).

The rewrite management section does not specify rewriting. I have 5 categories and 5 types of storage, so it is not recommended to create rewriting rules manually.

How can i solve this? Why weren't the rewriting rules written when we created / modified the URL of each category?

+3
source share
1 answer

1) Can you check if urlkey is definable at the store browsing level, or if it is set at the website level? This way you can only create 1 url key for EN and ES. You need it to be at the store view level, define two separate values.

2) Is there something in your error log? (and is your error log enabled?) Typically, rewritable URLs are automatically created for each store type. If not, you may need to manually reindex.

It is difficult to give further advice, since the problem can be anywhere (conflicting code? Bad code?)

0
source

Source: https://habr.com/ru/post/1394183/


All Articles