Woocommerce Rank Math module categories sitemap

#949525
  • Resolved Lauris
    Rank Math free

    Hello so we are having a problem with Woocommerce Rank Math module.

    We are generating sitemap and we have 2 languages whcih are managed with Polylang module.
    All content is generating properly, pages, products etc. Only issue seems liek is categories its generated only in main language, for secondary language no categories has been added to sitemap.

    Please let me know if u are aware if this issue. If not i can provide admin panel access or other information thats required.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Hello,

    We apologize for the issue you are facing with the WooCommerce Rank Math module and the sitemap generation for categories in your secondary language.

    Currently, Rank Math is designed to work seamlessly with WPML for multilingual setups, and while it should ideally handle categories in multiple languages, there can be some issues when using other plugins like Polylang. Unfortunately, we do not have specific information regarding Polylang’s compatibility with Rank Math for generating category sitemaps in different languages.

    To troubleshoot this issue, we recommend checking the following:

    1. Ensure that your categories are properly translated in Polylang.
    2. Verify that the Rank Math settings are configured to include product categories in the sitemap.
    3. Check if there are any plugin conflicts that might be affecting the sitemap generation.

    If the problem persists, please reply to this ticket with any additional details or screenshots of your settings, and a human agent from the Rank Math Support team will assist you further. Thank you for raising this concern!

    Lauris
    Rank Math free

    Everything seems to be configured properly. I am adding administrator access for the site so u can check what could be the issue.

    Lauris
    Rank Math free

    We fallowed steps here – https://rankmath.com/kb/polylang-compatibility/ and seems like its solved now

    There is 1 additional problem tho. Well not super critical.

    Basically main shop page is in pages sitemap for both english and latvian, which is good.

    but then if we go to products sitemap, then there main laguage shop page shows up there as well for some reason. Secondary language shop page does not show up there which is ok. But why is primary language shop page in product sitemap in first place.

    Hello,

    The shop page is included as the archive in the product sitemap. Google recommends including the archive of the post type in the sitemap and that’s why our plugin includes the shop page in the product sitemap.

    Hope that helps and please do not hesitate to let us know if you need our assistance with anything else.

    Lauris
    Rank Math free

    Is there any way to remove it from product sitemap so its not dublicated in pages and products sitemaps?

    Hello,

    You can use the following filter to remove the archive URL:

    add_filter( 'rank_math/sitemap/post_type_archive_link', function( $archive_url, $post_type ){
    	if ($post_type == 'product') {
    		return '';
    	}
    	return $archive_url;
    }, 10, 2 );

    Here is how to add a filter to your site: https://rankmath.com/kb/wordpress-hooks-actions-filters/

    You might have to follow this screencast to flush the sitemap cache after adding the filter: https://i.rankmath.com/pipRDp

    Hope that helps and please do not hesitate to let us know if you need our assistance with anything else.

    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.

Viewing 6 replies - 1 through 6 (of 6 total)

The ticket ‘Woocommerce Rank Math module categories sitemap’ is closed to new replies.