Custom post types are an essential part of most of the WordPress projects we work on. However, the lack of a ‘page’ in WordPress for users to edit their content is often problematic and confusing for users.
In this video, I will look at how we tackle this as a WordPress agency to make content management easier for our clients.
Our Post Type Archive Pages plugin in action
This plugin provides the ability to have a normal post edit screen which can be used for the post type archive pages. One of the problems with post type archive views in WordPress is that there is nowhere to edit the content of this page in WordPress e.g. page title. The plugin adds a menu item in the WordPress admin for each post type marked as having an archive when it was registered. When this menu item is clicked it gives a normal post edit screen where users can add a title and content as well as a featured image. These can then be output on the post type archive pages.
I forgot to mention in the video, but if you are ever using functions which are declared in a plugin you should always wrap them in a call to check whether the function exists first. This means that if the plugin is disabled, the code won’t lead to errors.