Bỏ qua điều hướng

Waiting for author

Topic Tags: Compatibility

Overview of the issue

When using WPML with the Flatsome theme and translating pages manually (using the native WordPress editor method), any changes made in the default language overwrite the translations. This issue occurs specifically when the UX Builder is used to edit the content.

Workaround

Please, make sure of having a full site backup of your site before proceeding.

  • Open your theme’s functions.php file.
  • Add the following snippet:
    add_filter( 'wpml_pb_is_editing_translation_with_native_editor', function( $isTranslationWithNativeEditor ) {
        if ( isset( $_POST['action'] ) && 'ux_builder_save' === $_POST['action'] ) {
            return true;
        }
    
        return $isTranslationWithNativeEditor;
    } );
    

Để lại câu trả lời

Please stay on topic and be respectful to others. If you need help with issues not related to this post, use our Support Forum to start a chat or submit a ticket.

Bạn có thể sử dụng các thẻ này:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>