0

Desired URL structure:

http://example.com/tips - page

http://example.com/tips/post - CPT

http://example.com/tips/category - custom taxonomy with hierarchy - parent

http://example.com/tips/category/child-category - custom taxonomy - child

I've found a solution that works in principle following this:

https://someweblog.com/wordpress-custom-taxonomy-with-same-slug-as-custom-post-type/

It effectively adds a new rewrite rule for each new category and you must have a permalink base of /%postname%/.

Question... has anyone faced similar, how did you overcome this? Will we have large performance hits as the custom taxonomy category count hits 100s+ rewrite rules?

  • Is it super important that the URLs be exactly those? This becomes considerably easier if you accept having a URL like http://example.com/tips/category/category-name/, where the URLs for categories will include the word category. The complexity comes from trying remove that part, because then WordPress doesn't have a way to distinguish categories from posts. – Jacob Peattie Jul 30 '18 at 10:46
  • @JacobPeattie Tell me about it... it's key to the project. Our client has an SEO expert who has laid out the plan. The site is due to scale dramatically and nailing the above structure will have major SEO benefits – Sam Holguin Jul 30 '18 at 10:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.