What is the physcial difference between enabling true or false for the ‘Hierarchical’ option under the settings? Does it affect the URL?
It can, depending on what you do with your posts. Hierarchical basically makes the post type behave more like pages, where you can have that parent/child page relationship that you mention. If I had a post type named “food” and a parent page of “sandwich”, and a child page of “turkey”, when I viewed that turkey post, the url would be something like mysite.com/food/sandwich/turkey/
This only affects posts within the post type, not multiple post types being “related” to each other. A post type of “food” would not be a child of a post type of “drink”. They don’t mix that way.
Getting post type slugs and taxonomy slugs in the same url and viewing content is not something our plugin covers at all, though it’s often a question. That delves into the areas of permalink customization and rewrite api. That said, it’s definitely possible from everything I’ve seen and experienced in my time with WordPress, but it’s more involved at the code level.
Is it okay If you check out my friends post regarding our website please? We really need to get a structure sorted out for our website but we have no idea which way we should go with it. There is currently onlt the two of us, wtuh myself knowing slightly more about WordPress. It’ll be nice to know if your plugin will be of any help and obvisouly because the custom URL strucute is going to require some custom coding where can we seek advice on this? I have tried the Stack Exchange forums but I only got one reply.
https://wordpress.org/support/topic/required-help-for-website-structure/
Many thanks for your help so far
Kind regards
Will
In regards to your exmaple, I created a CPT called ‘food’ and then created a taxonomy called ‘ sandwich’. I then headed over to the new ‘food’ menu and added a sandwich (category) called ‘ham’. Finally I clicked ‘add new food’ and named the title ‘tasty’ and the URL automatically defaulted to http://test-site.com/food/tasty/. However, I was expecting http://test-site.com/food/sandwich/ham/tasty.
Is there something I’ve I missed? P.S I have the ‘Rewrite’ and ‘Hierachal’ settings set to true in the CPT and taxonomy.
Will
I sadly don’t have any readymade answer for this type of customization and extension, as it always ends up me doing trial/error for it. The permalinks you’re seeing are what I am familiar with seeing for structure, out of the box with WordPress.
As an alternative, I believe I’ve recommended https://wordpress.org/plugins/permalinks-customizer/ in the past, but don’t really have any hands on experience with it.
Worth a shot.