When you need a template for a regular page or post, the Divi Library is your ultimate design resource. This is where you can store your favorite sections, layouts rows, or modules to use later. Toolset does not interfere with how you build the pages using your favorite builder.
Toolset allows you to design templates for custom post types using the Divi Builder. This means creating one design for all your posts, thereby creating your own custom post type. If you ever need to tweak this design, you can simply edit one template and the changes are automatically applied to all the custom posts.
The following three images show three posts displayed with a template created using Divi Builder and Toolset.
To build a template for your custom post types, follow the instructions stated below:
- Go to Toolset -> Dashboard.
- Locate the custom post type for which you want to create the template and click on the Create Content Template button.
- You will be taken to the Content Template editor. Click on the Edit with Divi Builder button to edit this template.
- Click on the Edit with Divi Builder button to start editing.
- Now, use the three basic building blocks (Sections, Rows, and Modules) to build your template. In this integration, every Divi Module can be used to insert custom fields in your template:
- Use fields in the Divi Text module when you simply want to display the fields. Toolset takes care of the output and matches the design with that of the Divi Module.
- Use fields in any of the Divi modules when you need to use them as arguments. As an example, you can display a short code in the Button module.
The Divi templates, that you design, can include static elements and fields from your content. Learn how to display fields and content-lists in templates.
- This is how our Content Template for Tours looks like. Click on Update.
- The Divi Builder lets you design the template. To complete the template, you need to access the other controls that appear on the Toolset Content Template page. When you finish editing, return to the Toolset Content Template editor.
- From this moment, all the items in your custom post type “Tours” will have the exact same content template that was built using the Divi Builder. If you tweak this template later, the changes will be reflected for all the posts under Tour.
Let us look at the “Gondola ride in Venice” post. On the top right corner, you can see that the Content Template that was automatically assigned to the post is the same one we built with the Divi Builder.
In conclusion, we used the Divi Builder to create a template (left) and the front end custom post (right) without any extra coding.
|Template of my custom post types built with the Divi Builder||How my custom post types looks on the front-end|
Toolset allows you control the settings of Divi for the different content templates that you design. This means that you can enable and disable sidebars or change the header and footer options for the template you are designing.
Currently, this is how a custom post type looks like on the front-end. There is a navigation bar, a logo, and a sidebar. These are the default theme settings.
We can easily change the theme options for this specific template. As an example, consider the method to remove the sidebar.
You can customize the theme settings in the last section of the Content Template editor.
Hint: You can reach the Content Template editor from Toolset -> Dashboard and then select the template you need to edit.
Once the editor is open, scroll down to the Theme Options section as shown below:
Initially, all settings are set at Use Theme Settings. This means that each of these settings comes from what you have selected in the Divi’s main options. Click on any of the settings to change it for the specific template that you are editing.
If the Sidebar is to be disabled, then we also need to select Fullwidth in the Layout Settings section:
Once we save the Content Template, the posts that use it (in our example: Tours) will all be displayed without the sidebar:
However, this change only applies to content posts that use the edited template. Other parts of the site are unaffected by the changes and continue to display as before.