Install CPT UI.
Under the CPT UI, click Add/Edit Post Types.
- Post Type Slug = singular lowercased name eg.
product - Plural Label = plural first-letter capitalised eg.
Products - Singlular Label = singular first-letter capitalised eg.
Product - Click the Auto populate label link
In the settings section...
- Has Archive =
truewith the textbox should be the plural lowercased name of the post type. - With Front =
false - Menu Icon = whatever icon represents the post type eg. products is a shopping bag.
- Supports = title, editor, featured image, excerpt; all ticked.
- Click Add
Under the CPT UI, click Add/Edit Taxonomies.
- Taxonomy Slug = descriptive category slug with underscores eg. product categories would be
prod_cat. - Plural Label = Free text of the category plural eg.
Product Categories. - Singular Label = Free text of the category singular eg.
Product Category. - Click the Auto Populate labels link.
- Attach to Post Type = Check the post type just created from above eg.
Products.
In the settings section...
- Hierarchical =
true - Custom Rewrite Slug = lowercase plural of the post type eg.
products - Rewrite With Front =
false - Click Add
- Go back to the Add/Edit Post Types, and click the Edit Post Types tab, and select your newly created post type from the select box (if not already selected).
- Scroll all the way down to the bottom of the page, and under Taxonomies check the newly created taxonomy to associate them with the post type.