Resolved

Resolved in: 3.6.3

Symptoms

Enfold’s page builder keeps a raw copy of the content in a custom field _aviaLayoutBuilderCleanData which is displayed depending on some other custom fields. As a consequence, in some cases, certain page builder elements might not be rendered correctly.

Workaround

This issue will be addressed in a future version of WPML. Meanwhile, we suggest the following solution:

  1. Go to the WPML -> Translation Management page and click the Multilingual Content Setup tab. There, go to the Custom Field Translation section.
  2. Click on Show system fields.
  3. Set the custom fields as follow:
    • _aviaLayoutBuilder_active => copy
    • _avia_builder_shortcode_tree => copy
    • _aviaLayoutBuilderCleanData => don’t translate

In some cases, some shortcodes might not be correctly parsed on the translation, so add the following snippet to your theme’s functions.php file:

function wpmlcore_3937_fix_for_enfold_page_builder( $post_ID, $post ) {
if ( class_exists( 'WPML_Compatibility_Theme_Enfold' ) ) {
return;
}

$page_builder_active = get_post_meta( $post_ID, '_aviaLayoutBuilder_active', true );
$page_builder_shortcode_tree = get_post_meta( $post_ID, '_avia_builder_shortcode_tree', true );

if ( $page_builder_active && $page_builder_shortcode_tree ) {
update_post_meta( $post_ID, '_aviaLayoutBuilderCleanData', $post->post_content );
}
}
add_action( 'wp_insert_post', 'wpmlcore_3937_fix_for_enfold_page_builder', 10, 2 );

If the problem persists, please open a ticket on the support forum.