Skip Navigation

This thread is resolved. Here is a description of the problem and solution.

Problem:
There are "too many redirects" when trying to open a Russian translation of a product. This only happens for Russian products, while product categories even translated into Russian are just fine.

Solution:
This is a known issue between WPML and Rank Math. We've contacted the plugin authors about this issue and they suggested disabling the product redirection by using this filter: https://rankmath.com/kb/filters-hooks-api-developer/#disable-custom-product-redirection

To fix this issue, please follow the workaround mentioned here: https://wpml.org/errata/rank-math-seo-err_too_many_redirects-error-on-woocommerce-products/

This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

Tagged: 

This topic contains 8 replies, has 3 voices.

Last updated by raidoL 1 year, 8 months ago.

Assisted by: Mohamed Sayed.

Author Posts
May 8, 2023 at 6:43 am

raidoL

Hi I have Hreflang to redirect or broken page on my site Luxsauna.fi on Russia language. and Russia language products have error when I try to open them

May 8, 2023 at 8:05 am
May 8, 2023 at 8:07 am #13602799

Waqas Bin Hasan
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Hi,

Reference to our recent chat, meanwhile this ticket is attended by our support, please feel free to update about your findings on your staging site by activating other plugins one by one and keep checking for the issue.

You can also try reproducing the same thing on the Sandbox provided to you. This 'll help finding the differences as well as identify the actual problem.

Regards.

May 8, 2023 at 8:14 am #13602813

raidoL

I found the conflicting plugin: Rankmath SEO

It cause translated Russian Language products to have an error - It's portably because having % in the link/href?

When I disable Rankmath all the products in Russian language work perfectly and when I enable the plugin, same links do not open anymore with error "too many redirects"

Kind regards,
Raido

May 8, 2023 at 1:04 pm #13605889

Mohamed Sayed

Hi Raido,

I checked the product URL and found multiple 301 redirects created by Rank Math, please see here: hidden link

Please enable the plugin again then go to Rank Math > General Settings > WooCommerce tab, and check the status of the following options:

- Remove base
- Remove category base
- Remove parent slugs

If any of them is enabled, disable the option then resave the permalinks settings in Dashboard > Settings > Permalinks and check if the issue is resolved.

Let me know please how that goes.

Regards,
Mohamed

May 8, 2023 at 1:46 pm #13606149

raidoL

Hi,

Yes, you're correct, if I disable "Remove base" then Russia product links works again.

But why is it only with Russia language products?

Also, I need to keep remove base disabled for SEO...

Kind regards,
Raido

May 8, 2023 at 3:46 pm #13607313

Mohamed Sayed

Hi,

I'm not sure why it happens only with one language, but it seems related to a known issue between WPML and Rank Math. We've contacted the plugin authors about this issue and they suggested disabling the product redirection by using this filter: hidden link

If you want to use this option, please follow the workaround mentioned here: https://wpml.org/errata/rank-math-seo-err_too_many_redirects-error-on-woocommerce-products/

I hope that you will find this information helpful.

Regards,
Mohamed

May 8, 2023 at 4:41 pm #13607581

raidoL

Yes, using it removes the redirect error, but I would like to know what does redirect do? won't it affect SEO when I disable it?

May 8, 2023 at 5:46 pm #13607947

Mohamed Sayed

Hi,

The redirect is created by Rank Math and the filter used in the workaround is provided by the plugin authors, so I'm afraid you'll need to check about it with their support.

Since your site's SEO is controlled by this plugin, they can also help you better regarding the other question as we are not sure how this can affect your SEO.

Kind regards,
Mohamed

May 9, 2023 at 8:29 am #13611063

raidoL

Ok, I will ask Rankmath support. My issue is resolved for now. Thank you!