• Resolved moj

    (@modernite)


    When using “Shop base with category” as the Product Permalink, when viewing a single product page, the category name in the permalink can be set to anything and still shows the single product without redirect or 404 error for example ::

    this is my single product link

    https://XXXXXX/shop/battery/single-product/

    you can Replace the category slug in the URL with anything and the page is available with that link :::

    https://XXXXXX/shop/you-can-write-anything-here/single-product/

    Do you have any solution for this?

Viewing 1 replies (of 1 total)
  • Hello @modernite

    This is actually an intended feature of WooCommerce, designed to prevent broken links and enhance the user experience. The idea is that even if the category slug is changed or mistyped, the customer can still reach the product page.

    However, if you want to enforce strict URL structures, you might consider using a plugin that manages redirects or enforces canonical URLs, or we strongly recommend hiring a developer or contacting one of our WooCommerce experts if you’re not comfortable coding. We highly recommend contacting one of the services on our Customization page.

    Alternatively, you could consider using a plugin like Redirection and another one is Yoast SEO (both from ww.wp.xz.cn repository), which includes advanced permalink controls and sets canonical URLs to avoid duplicate content.

    Please note that incorrect setup can lead to problems like infinite redirect loops. Always backup your site before making major changes, and test thoroughly.

    I hope it helps!

Viewing 1 replies (of 1 total)

The topic ‘Shop base with category Permalink issue’ is closed to new replies.