Skip Navigation

[Resolved] The full-width option from DIVI is not applied to posts that use a given Content Template, when created with CRED

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

Problem:
When posts are added using CRED forms, and you use a Content Template with DIVI Theme options for those posts, then the full-width setting is not respected.

Solution:
None for now.
This is a workaround:
https://toolset.com/forums/topic/custom-posts-created-with-front-end-form-are-ignoring-divi-layout/#post-582923

Relevant Documentation:
https://toolset.com/errata/the-full-width-option-from-divi-is-not-applied-to-posts-that-use-a-given-content-template-when-created-with-cred/

This support ticket is created 6 years, 5 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
- - 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00
- - - - - - -

Supporter timezone: Asia/Ho_Chi_Minh (GMT+07:00)

This topic contains 2 replies, has 2 voices.

Last updated by mirkoG 6 years, 5 months ago.

Assisted by: Beda.

Author
Posts
#582789
01.png

I configured the content template for my custom post type to always apply the fullwidth layout in DIVI (picture 01). When I create a post from the dashboard, it correctly utilises the fullwidth layout. When creating a new post from the front-end with the form I created with CRED, a sidebar appears.

Example:

This was created from the dashboard: hidden link
This was created via the front-end form: hidden link

Did I miss anything?

#582923

I confirm this issue.

A temporary solution can be to apply a Custom CRED API action and update the "_et_pb_page_layout" field of the newly created post with the correct value on submit (et_full_width_page).

This is elaborated here:
https://toolset.com/documentation/programmer-reference/cred-api/#cred_save_data

An example code can be:

add_action('cred_save_data', 'my_save_data_action',10,2);
function my_save_data_action($post_id, $form_data)
{
    // if a specific form
    if ($form_data['id']==12)
    {
       
          // add it to saved post meta
          update_post_meta($post_id, '_et_pb_page_layout', 'et_full_width_page');
        
    }
}

This will update the Field on submit of the CRED form and ensure that the right Layout is applied.

I will escalate this problem and report back to you once we have a proper solution.

#582999

It worked thanks.

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.