How to Create Custom Post Types in WordPress without Writing Any Code

On
An illustration of custom blog post typesGeneral WordPress users are comfortable and happy with the regular posts available in the default installation. Whenever we talk about 'Custom Post Types', an average user scratches his head wondering what we're talking about. In simple words, custom post types transform a typical WordPress blog installation into full-blown content management system with custom types of contents. In the following sections, we'll know what exactly a custom post type is and how we can create one for ourselves. As indicated in the title of this article, we won't be messing with code at all in getting things done. We'll use a powerful and flexible plugin that will help you create custom post types quite easily. While testing the implementation of custom post types, use a demo or dummy blog to get hold of things instead of trying it out on a live blog site.

An illustration of custom blog post types

Before creating a custom post type, always brainstorm about the structure and metadata associated with such a post. This way, the custom post-type creation process will be a cakewalk.

Read Also:
Best No-Code Page Builders to Build Custom Websites With WordPress

If you possess working knowledge of PHP, you can enhance the custom post-type creation process in many folds. But, it is not absolutely necessary as the solution given here is a no-code tool.

What Are Custom Post Types?

WordPress at its core can store and display different types of content. Each type of content is essentially a type of post. For example, the regular blog posts published on a blog are of 'post' type. Every single static page created on a WordPress blog is of 'page' post type. We all know WordPress also stores older versions of the same blog post in the form of revisions. To distinguish these revisions from the most current version, these older copies are stored as 'revision' post type.

A custom post type is a new user defined logical content box to store and display specific type of content with added meta data, if required.

WordPress users can create their very own post types to store and display a specific type of content. To understand it more clearly, let's see a simple example.

Let's assume you're running a literature blog publishing about various types of books. Instead of using the default 'post' type, you can create a custom post type named 'book' that can be used to store and display information about all the books you want to write about on the blog.

You can also assign a more logical post type slug to these custom post types for a more natural and obvious permalink structure. For example, the post slug of the custom post type discussed above can be...

http://www.yourdomain.com/book/wordpress-for-beginners/
Note the word 'book' is used in all the blog posts published under this custom post type. On the admin front within the dashboard, the post writing experience also makes more sense because the custom post type editing screen prompts you to 'Add New Book' instead of 'Add New Post'.

You can also enable dedicated archives pages of every custom post type created by you and can make them searchable too. There are dozens of advanced options that can be added with every custom post type.

So let's get started and see how we can easily create our own custom post types that meet our requirements.

Creating Custom Post Types Without Any Code

Head over to your test blog and install the powerful WCK Custom Post Types Creator plugin. Although there are several other powerful and flexible features bundled with this plugin, we will solely concentrate on the basic custom post type creation process.

Once you get familiar with it, you can explore all other available options. So without any delay, let's create a sample custom post type based on the example discussed above. After installation and activation, you can access all the plugin options by visiting the 'WCK' option within the dashboard menu.

Click the 'Post Type Creator' option to open the editing interface for creating a new custom post type. I'll mention all the vital fields that need to be filled or edited. The remaining fields can be either skipped or can be changed or filled as per your needs.

Custom post type creation dialogue box
  • Post type - This is a mandatory field that gives a name to the custom post type you're going to create. Keep it short and precise for the best results. You cannot use white spaces, hyphens and capital letters in this field and the total length shouldn't exceed 20 characters. In our example, I'll give it a value - 'book'.
  • Singular Label - This is yet another mandatory field that specifies the text label to be used on the admin user interface while working with this custom post type. Start the name of this field with a capital letter. In our case, I'll put the value - 'Book' in it.
  • Plural Label - This mandatory field is similar to the one mentioned above. This text label is used within the admin user interface whenever you're dealing with multiple instances of the said custom post type content. I'll put the value - 'Books' in this field.
  • Has Archive - If you want this custom post type to have separate archive pages like the normal posts, you can select 'true' for this option.
  • Supports - This option will let you select additional features that can be activated for this custom post type. For example, you can enable comments which are disabled by default. There are several options/features that can be enabled through this option and it is entirely your choice to enable select features.
You will find two links to open advanced options. Click both of them to expand the drop down displaying all the available advanced options that can be fine tuned before pressing the save button.

  • Advanced Label Options - Under this expanded menu, you can specify the user friendly or more meaningful text labels used across the admin user interface while composing content for the respective custom post type. For example, instead of the label 'Add New Post', you can configure a custom label 'Review New Book'.
  • Public - You must leave the default value ('true') of this option as it is else neither you it will be able to add posts to this custom post type within navigation menus nor it will be searchable by users. Several other actions will also not work if this option is set to false.
  • Show UI - As the name implies, this option ensures the front end user interface for managing this custom post type is visible and accessible within the dashboard. Since the default setting for this option is 'true', you can leave it as it is.
  • Show In Nav Menus - Again the option name itself explains its effect. Leave the default value to 'true' to ensure the custom post type is available for including in custom navigation menus that are created during the designing phase of your website.
  • Show In Menu - This option ensures that management interface tab for the custom post type is included in the main dashboard admin menu on the left side.
  • Taxonomies - This is another important option that must be used if you want to logically group the content on the basis of tags or categories. In case, you want to create custom taxonomies for this custom post type, you must first create that through this plugin before triggering the custom post type creation process.
You can leave rest of the options as it is and can save the record by clicking the 'Add Entry' button.

Now you can visit the 'Book' custom post type administration interface on the left side menu to manage the custom content you want to publish through this new custom post type.

If you want to modify, edit or change the settings of this custom post type, you can do that too through the edit link provided for the respective custom post type within the plugin interface. Hope this tutorial will help you develop a better content management system for yourself as well as for your clients.