Skip Navigation

[Resolved] Using Toolset with Divi Theme Builder for CPT and CPT archive templates

This thread is resolved. Here is a description of the problem and solution.

Problem:

I am just trying to determine the best way to move forward with creating a CPT template and CPT archive template using the latest Divi theme and Toolset.

Solution:

You can follow our document to use Toolset plugins with DIVI page builders:

https://toolset.com/course-lesson/using-toolset-with-divi/

Relevant Documentation:

This support ticket is created 3 years, 9 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

This topic contains 9 replies, has 2 voices.

Last updated by richard-mazzafroM 3 years, 8 months ago.

Assisted by: Luo Yang.

Author
Posts
#2017775
Screen Shot 2021-04-11 at 5.01.32 PM.png

Hi, I am just trying to determine the best way to move forward with creating a CPT template and CPT archive template using the latest Divi theme and Toolset. I was thinking I could create a View in Toolset with the CPT custom fields, but not create Toolset templates for the custom post type and the custom post archive, but instead use a Divi Toolset Module in Theme Builder templates for the CPT and CPT archive to add the Toolset view. Is that the best way to do this, or will Divi Theme Builder templates not work with Toolset views in this way? Thanks for any clarification you can provide. Attached is my custom post type setup as shown in the Toolset dashboard.

#2017955

Hello,

I suggest you follow our document to use Toolset plugins with DIVI page builders:
https://toolset.com/course-lesson/using-toolset-with-divi/

One issue need to pay attention to:
Toolset Blocks plugin is based on WordPress Blocks Editor, and DIVI page builder is another page builder, so it is not recommended to design the same page/post with two page builders.

If you want design a content template with DIVI page builder, and display a post view in the DIVI page builder, you can setup the post view with classic editor:
1) Dashboard-> Toolset-> Settings-> General:
in section "Editing experience", enable option "Show both the legacy and Blocks interface and let me choose which to use for each item I build"

2) Dashboard-> Toolset-> Views
Create a post view with classic editor, then insert this view's shortcode into DIVI page builder content:
https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-view

#2018195

Thank you, Luo. It might be useful to go the shortcode route instead of using Toolset Blocks or the Divi Theme builder, but I just want to clarify, I am not talking about the Divi builder itself, but specifically about Divi's Theme Builder option, which is new with Divi 4.x and allows you to build templates for any CPT or CPT archive and assign them to be used only for posts/archives that match that CPT. I was hoping to create Theme Builder templates for my CPT and CPT archive, build a Toolset view for the CPT, and then insert a Toolset Views block with that view into each of those Theme Builder templates, and then I would not be creating a template in the Toolset Dashboard for this CPT. I don't expect you folks to be Divi experts so I apologize if my question is beyond the scope of what you are able to assist with, and I will run this by Divi support also to see what they have to say. Thanks again for the info.

#2018211

Thank you for the info, Luo and it may be better to try the shortcode route here with Divi. Just to be clear, I am not speaking of the Divi builder itself, but the Divi Theme Builder features, which were added in Divi 4.x and allow you to create a template, using the Divi builder, that can be assigned to any post, page, custom post type, archive etc. but can be built using the Divi builder. So my intention was to create two templates in the Divi Theme Builder, one for my CPT and one for my CPT archive, and then, using Toolset, create a Toolset View for the CPT w/the custom fields. I would then insert that Toolset View into the Theme Builder template, and I'm good to go, with all my custom fields appearing as needed.

Divi's Theme Builder does allow you to create a template for any CPT, and also include custom fields in the template, but it does NOT allow you access to any custom fields when creating a CPT archive template. That is why I need to use Toolset/Toolset Types.

I do not expect you folks to be Divi experts, and I am also running this by Divi support, but I just wanted to make sure I am creating this in the best way going forward. Thanks again for your assistance.

#2019133

In Toolset side, if these custom fields are created with Toolset Types plugin, you can display them with Types shortcode [types ...][/types], see our document:
https://toolset.com/documentation/customizing-sites-using-php/functions/

You can also use Views shortcode [wpv-post-field] to display other simple custom fields:
https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-post-field

#2019415
Screen Shot 2021-04-13 at 8.27.07 AM.png

Thanks, Luo. That helps clear things up. One minor question, just curious as to why the default Post template in our theme has no archive. Doesn't WordPress create this automatically regardless of whether Toolset is installed? See attached. Projects is a CPT that is part of the theme, that's got no archive either but I am not concerned about that since we won't be using that CPT anyway.

#2020211

The "WordPress Archive" means Toolset WordPress Archive, you can find or create them here:
Dashboard-> Toolset-> WordPress Archive, more help:
https://toolset.com/course-lesson/creating-a-custom-archive-page/

#2021303

Got it, thank you Luo. I was reading that as the theme itself was missing the archive page. I do have one more question, how to make a second custom field appear on a new line, as opposed to a new paragraph, when I use the Fields and Text option? I tried shift-return and also manually entering <br /> in HTML mode but neither seem to work... They seem to be automatically separated with <p> tags with no way to change that.

New threads created by Luo Yang and linked to this one are listed below:

https://toolset.com/forums/topic/how-to-make-a-second-custom-field-appear-on-a-new-line/

#2021573

I assume the original question of this thread is resolved, according to our support policy, we prefer one ticket one question:
https://toolset.com/toolset-support-policy/

For other new questions, please check the new thread here:
https://toolset.com/forums/topic/how-to-make-a-second-custom-field-appear-on-a-new-line/

#2024243

My issue is resolved now. Thank you!