Showing results for 
Search instead for 
Did you mean: 

Catch 404s for wrong locale url_path

Catch 404s for wrong locale url_path

Hi, we are having a little issue, maybe some smart person knows a fix?
We have a few different locales, e.g. NL and UK.
A typical product has a different name for both countries, thus a different url_path. Like this:
UK ->
NL ->

Now, when you enter the store from another, for example Google URL, like this:
NL ->
This results in a 404 page (and this happens a lot I might add).

We have created a 404 page with a link like this on it:
[a href="?___store=locale_store_nl"]

However, this is not foolproof.

How can we make sure these 404 errors do no longer exist. We have a .nl domainname as well, but we wanted to keep everything in the .com version this time. In the .nl domain we have an htaccess file that does this, but that only helps when WE put the link somewhere. Anybody sharing or pasting the link they then see elsewhere, will send their visitors to the 404 because of the default locale of the UK version.
RewriteRule ^(.*)$$1?___store=locale_store_nl [QSA,L]

A 404 extension that just catches all 404s doesn't work, because this creates a loop somehow.
We need something that knows the NL product url_path belongs to the NL locale, and not go to a 404 when entered through the UK locale.

I hope this made sense.

Who went through this before?