Dmitry
Dmitry

Reputation: 155

Same links in different WooCommerce categories

I'm sorry for my question, but I couldn't find an answer.

I have several WooCommerce categories and subcategories:

/new-york/apartments
/paris/apartments
/madrid/elite/apartments

It is very important that the subcategories have the same names in the links.

I understand that the WordPress structure does not allow such links and adds the name of the previous category:

/madrid/elite/apartments-elite

But maybe there's some way to fix it? It's very necessary.

Thank you so much in advance!

P.S. May be, could it be done with redirects?

Upvotes: 1

Views: 598

Answers (1)

user4563161
user4563161

Reputation:

You're categorising your pages in the wrong manner.

You should have a category called Appartments and inside that category have pages, products subcats for the location.

e.g. apartments/new-york/

That way you have the main page called apartments as you want. With the ability to then select a location.

But to be honest it looks like you should be using tags. Tags allow multiple selections. For instance, you could have a tag for new york and a tag for apartments. So then you just have a page that calls new-york apartments or whatever tag selections you need.

Woocomerce Product Tags

Upvotes: 1

Related Questions