-
Hi there,
There is double // in the end of url for translated product schemas which are generated by RankMath.
Image in the sensitive data, including url.
Please let me know how to fix this?
Kind regards,
Raido
-
Hello,
Thank you for contacting us and sorry for any inconvenience that might have been caused due to that.
As you’re using the WPML, please install the WPML SEO glue plugin as well (if not yet). It’s available on your WPML Downloads page: https://wpml.org/compatibility/2021/04/wpml-seo-plugin-better-integration-with-seo-plugins/
Once done, please remove the current WooCommerce Product Schema from that page and re-add it from the Schema Generator and see if that resolves the issue.
Let us know how it goes. Looking forward to helping you.
Thank you.
Hi there,
We have the WPML SEO glue plugin installed (we did it at the same time when we installed WPML).
Yes, when I disable RankMaths WooCommerce Product Schema and immediately reenable it, the double slash in the url is fixed.
But why is it happening? It is on all products that we recently translated.
Best,
RaidoHello,
The integration between Rank Math and WPML may not be configured properly before the after the Woocommerce Product schema has been added to your products. However, I can still see the double slash is still in the affected product’s schema.
We might need to take a closer look at the settings. Please edit the first post on this ticket and include your WordPress login in the designated Sensitive Data section.
Please do take a complete backup of your website before sharing the information with us.
It is completely secure and only our support staff has access to that section. If you want, you can use the below plugin to generate a temporary login URL to your website and share that with us instead:
https://wordpress.org/plugins/temporary-login-without-password/
You can use the above plugin in conjunction with the WP Security Audit Log to monitor what changes our staff might make on your website (if any):
https://wordpress.org/plugins/wp-security-audit-log/
We really look forward to helping you.
Hello,
I have updated the sensitive data as requested. Can you please check further?
Thank you.
Hello,
Our plugin adds a trailing slash to the seller ID in the Schema markup for the products and since your website already has the trailing slash in the home URL it gets added to it and the slash is repeated.
This is only happening on that particular property and since it’s an ID that is used to connect the markup it won’t cause any issues because the website will still product compliant markup.
Don’t hesitate to get in touch if you have any other questions.
Secondly, these urls come up as Page with redirect (in the search console).
Hello,
The page you shared has a redirect in place as you can see from this screenshot:
The redirection is being handled by the WPML plugin installed on your website as you can see from the header
redirected-by
on the screenshot.Regarding the canonical, this won’t cause any issues since the canonical doesn’t have any double trailing slashes as this only happens in the ID of the
seller
property which is not usable by Search Engines but rather only usable by our plugin for internal Schema management.Don’t hesitate to get in touch if you have any other questions.
Sorry, but you got it wrong. Page with redirect means that this page is redirected. Therefore, WPML redirecting has nothing to do with what I explained.
1st error (https://ibb.co/hXWX3L3, https://ibb.co/tJ17QMn) we have is: Alternate page with proper canonical tag for a URL https://luxsauna.fi/en//
It’s because Google reads these double // urls and marks them as wrong canonicals. It needs to be fixed.
2nd error (https://ibb.co/LSN2tXP) because of these double // is these same pages are redirected:
https://luxsauna.fi/et// to https://luxsauna.fi/et/
https://luxsauna.fi/sv// to https://luxsauna.fi/ev/
https://luxsauna.fi/de// to to https://luxsauna.fi/de/
etc.NB! It doesn’t matter if referring page is now redicted by WPML or not – its where the search engine found above mentioned links at first.
In conclusion, it is crucial to address the issue of double forward slashes (//) in our products so we can eliminate ‘Alternate page with proper canonical tag’ and ‘pages with redirects’. If these elements are present across all our products and search engines find them, they can adversely affect our SEO as well as consuming our crawling budget.
Best,
RaidoHello,
Thank you for the screenshots to illustrate the issue and provide further context to it.
When you referenced the page with redirect we thought you were talking about the referring page where the URL was found, which also has a redirection that is set up by WPML as you can see from the image we shared previously.
To remove the trailing slash from these sorts of URLs, you can change line 73 of the file
wp-content/plugins/seo-by-rank-math/includes/modules/schema/snippets/class-product.php
to read the following:'@id' => $site_url,
This will remove the double slash from the language URL in the ID of the Schema markup and it will prevent any search engine from seeing it.
We are also going to report this internally so that our developers can improve this piece of code in the future.
Don’t hesitate to get in touch if you have any other questions.
Hi,
Great, that fixed it.
Will it stay like that even after I update the plugin?
Kind regards,
Raido
Hello,
For now, it will be reverted back to the original state upon updating the plugin but we have already added this feature improvement to our repository for our developers to assess it.
When they do, then it will remain correct with every plugin update and when that happens we’ll notify you of the same in this ticket.
Thank you.
Okei, thanks.
Best,
RaidoHello,
Glad that helped.
If you have any other concerns, please don’t hesitate to contact us anytime to assist you further.
Looking forward to helping you.
Thank you.
Hello,
We released a quick Beta update you can try to see if that helps.
Please enable the Beta update by following this:
https://rankmath.com/kb/version-control/#beta-updatesIf you are unable to see an update, please clear Rank Math’s transients from:
WP Dashboard > Rank Math > Status & Tools > Database Tools > Remove Rank Math Transients > Remove transients
Please clear the caches, server, and WordPress after updating.
You can disable the Beta updates once you update to the latest version and if the issue is fixed.
We are here to assist. Thank you.
I also suffered from this issue using WPML. The trailing slash meant pages became unindexed and this beta update fixed it. Subscribing to know when it gets rolled into main.
Hello,
Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.
If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.
Thank you.
The ticket ‘Double slash in WPML translated schema’ is closed to new replies.