This plugin allows you to squeeze some more SEO juice out of your website by adding your custom post type's taxonomies in your URL structure.
|Author:||Buks Saayman (profile at wordpress.org)|
|WordPress version required:||3.0.1|
|WordPress version tested:||4.7.5|
|Added to WordPress repository:||25-04-2017|
Click to start download
In your wp-admin dashboard, look for these settings. There you choose the custom post types you want to have the slug include the taxonomies for.
Example of what you can expect your URL structure to be.
Either install the plugin the traditional way through your Admin dashboard’s Plugins screen, or you can :
- Upload the plugin files to the
- Activate the plugin through the ‘Plugins’ menu in WordPress
- In WP-admin, look for
Custom Post Tax Hierarchyin your left-hand sidebar menu. There you must select which Custom Post Types for this to apply to.
Go to your custom post type posts, either in your Admin dashboard, or the front-end of your website, and look at the URL, it now includes all your custom taxonomy terms.
What if I don’t have any custom post types or taxonomies yet?
If you want a GUI interface through which to create your custom post types and taxonomies, I would recommend you use this plugin : https://wordpress.org/plugins/pods/.
Alternatively, if you are familiar with PHP, you could just follow the follow the Codex examples : https://codex.wordpress.org/Post_Types
What if I enable this plugin and all my posts are broken?
All this plugin does is create rewrite rules that maps your URL back to an actual post. If you find that after you’ve enabled this plugin, things go horribly wrong, simply disable the plugin and create a support request here.
Will this work for Woocommerce?
Not this specific plugin. I am still in the process of building a version that is compatible with Woocommerce. It is possible to do, but it won’t be a free version. If you’re interested in this for Woocommerce, contact me and we can chat.
Why do my URL’s now suddenly have a numerical suffix e.g /name-of-post-1234/
That’s a really good question. The answer is a bit technical. Becuase you could technically have a post and a category with exactly the same URL, we’ve had to add a way of differentiating between the two. For example you could have
domain.com/amazing-pictures/ which could be a category, but
domain.com/amazing-pictures/ could also be a single post. In WordPress they’re treated the same, but we need to know which is which. Therefore, your post will be suffixed by the unique post identifier. This is the industry standard way of doing it and is completely SEO safe.
- I forgot to flush permalinks after editing a taxonomy term.
- Fixing bug reported by @rbertrand. The plain taxonomy archive pages didn’t work. I added the rewrite rules for them.
- First bug fixes to make admin custom post type selection take effect.
- Initial release, have fun 🙂