WordPress is one of the most popular content management systems (CMS) in the world, with millions of websites using it to publish content. One of the key features of WordPress is its ability to create custom post types, which allow you to create different types of content beyond the traditional posts and pages.
While there are many ways to create custom post types in WordPress, one popular plugin for doing so is Custom Post Type UI (CPTUI). However, despite its popularity, there are several reasons why you may want to avoid using CPTUI for creating custom post types.
Limited Options
One major limitation of CPT UI is that it only provides an interface for taxonomies and custom post types, and does not offer any support for creating custom fields or more advanced features.
Custom fields are an essential component of many custom post types, as they allow you to add additional data and meta information to your content. For example, if you are creating a custom post type for a recipe website, you may want to add custom fields for ingredients, cooking time, and serving size. These fields allow you to enter and display specific information about your recipe that would not be possible with a basic post type.
While CPT UI may be useful for creating simple custom post types and taxonomies, it lacks the flexibility and functionality required for more complex content structures. If you require more advanced features like custom fields, meta boxes, or relationships between different types of content, you may need to look for other plugins or custom development solutions.
Dependency on a Plugin
By using CPTUI, you are adding another plugin to your WordPress site, which can create dependencies and potential conflicts with other plugins. It’s important to keep in mind that while plugins can be a powerful tool for customizing your site, they should be used judiciously and with care. When choosing which plugins to use, it’s important to consider factors like performance, compatibility, and security. You should also be mindful of the potential risks of adding multiple plugins to your site, and take steps to minimize these risks.
Security Risks
One of the benefits of using WordPress is the vast array of plugins that are available to extend the functionality of your site. However, it’s important to be aware that each plugin you add to your site has the potential to introduce security risks. CPT UI is no exception, and it’s important to take steps to ensure that using it doesn’t compromise the security of your website.
There’s Simply No Need
Creating custom post types and taxonomies using code has become increasingly accessible and straightforward in recent years, especially with the help of tools such as GenerateWP. With the ongoing development of WordPress and the availability of comprehensive documentation and tutorials, creating custom post types and taxonomies can be a simple and achievable task, even for those with minimal coding experience.
What to use instead?
Use CPT UI’s Export Functionality
You could use CPT UI, but only during development. When you are ready to go live, you could use the plugin export feature to export the CPT’s to code and include them in a tiny custom plugin. Really if you are going to use CPT UI, this is by far the best way to use it.
Make a Custom Plugin
Creating a custom plugin for this is trivial, and generating the code can easily be achieved using a tool such as the excellent GenerateWP, which has free tools for generating both CPT’s and taxonomies, it also produces easy to read, clean code.
One of the primary benefits of creating a custom plugin is portability. By creating your custom post types and taxonomies as part of a plugin, you can easily move them between sites without needing to recreate them from scratch. This can be especially useful if you have multiple sites that require the same custom content structure.
Another benefit of creating a custom plugin for your custom post types and taxonomies is that it comes with almost no overhead. By using the built-in WordPress functions, you can create a custom plugin that is lightweight and optimized for performance. This is in contrast to some custom post type plugins, which can be bloated and add unnecessary code to your site.
Use Advanced Custom Fields
The most recent release of Advanced Custom Fields (ACF) comes with the capability to create CPTs as well as taxonomies. If you are already utilising ACF, then this may be a good option for you; however, we would still prefer to make a custom plugin in order to reduce the number of dependencies that the project has.
Wrapping it up
In conclusion, while Custom Post Type UI may seem like an easy and convenient way to create custom post types in WordPress, there are several reasons why you should avoid using it. Consider creating these manually to avoid the overheard of another plugin.