Joshua Wieczorek
Joshua Wieczorek

Reputation: 735

Woocommerce Permalinks

I am trying to achieve the following Woocommerce permalink structure:

Shop Base:

"www.domain.com/shop"

Product Base:

"www.domain.com/shop/%product_cat%/%product%"

Category Base:

"www.domain.com/shop/%product_cat%"

However, for example, when I navigate to "www.domain.com/shop/tshirts", WordPress redirects me to a url "www.domain.com/tshirts" instead of "www.domain.com/shop/tshirts".

(Take note: I do have a page at the url "www.domain.com/tshirts" giving information on all of the different types offered, materials, designs, etc. However, the product category should not redirect here, it should be "www.domain.com/shop/tshirts" where the customer can see all "tshirts" in the category "tshirts" for sale.)

Am I doing anything wrong, or is this permalink structure prohibited by Woocommerce and WordPress?

Thank you.

Upvotes: 0

Views: 696

Answers (2)

Hemel
Hemel

Reputation: 441

Visit "General" -> "Permalinks" section in your admin panel, There you can see the shop based permalink below.

Upvotes: 0

rsella
rsella

Reputation: 337

Based on this you cannot set both product and categories permalinks to the same structure. The last note is:

Please note: The product custom base should not conflict with the taxonomy permalink bases. If you set the product base to ‘shop’ for example, you should not set the product category base to ‘shop’ too as this will not be unique and will conflict. WordPress requires something unique so it can distinguish categories from products.

Upvotes: 1

Related Questions