Custom fields are pieces of information that you can add to custom post types. When you use custom fields, you make both the content administration and display a lot simple. In the WordPress admin, writers will see the fields neatly organized and easy to edit. To display custom fields on the front-end, you will design templates.

Custom fields in the WordPress admin Custom fields on the site’s front-end
It's easy to edit this content, because each item appears in a separate fields
It’s easy to edit this content, because each item appears in a separate fields
The fields displaying on the front-end, using a template
The fields displaying on the front-end, using a template

How to add custom fields to content

The free Toolset Types plugin makes it easy to create custom content and to add fields to it. You can add fields to both “posts” and “users”. What we call “posts” is not just the blog post. WordPress uses the name “posts” for blog posts, pages and custom post types.

First, create the custom post types that you need. Once you’ve created custom post types, they will appear in Toolset Dashboard.

Toolset Dashboard
Toolset Dashboard

Click on the button Create field group and then on Add New Field to add fields to the group.

An fields group with no fields yet
An fields group with no fields yet

Choose the kind of fields to insert.

Different kinds of fields available from Toolset Types
Different kinds of fields available from Toolset Types

Then, set options for the field. All fields require a name and slug (the “machine name”). Some fields have additional settings.

Details for a field
Details for a field

After you’ve added all the fields that you need, remember to save the fields group.

Fields group with a few fields
Fields group with a few fields

After you save the fields group, it will appear when editing content.

The custom fields in the WordPress content editor
The custom fields in the WordPress content editor

Displaying custom fields on the site’s front-end

Now that you know how to add custom fields to the WordPress admin, it’s time to learn how to use them on the front-end.

If you are comfortable editing PHP, you will be able to display the custom fields on the front-end using Types PHP API. You can display custom fields without writing PHP using the full Toolset package. We offer refunds for up to 30 days for Toolset, so you can try it, risk free.

Continue reading: