Raw HTML and Raw JS emptied after duplicate

  • Unknown's avatar

    Hello,

    I encounter issue with WordPress Raw HTML and Raw JS, when I want to duplicate a post those elements are removed !

    I tried to enable the Unfiltered HTML in WP Bakery for each roles but nothing is working.

    The process I do is very simple, I’m getting some informations from the original post, put them into an array to duplicate it.
    To get the content of the post I do the following:

    $array[‘post_content’] = $results->post_content;

    And to create the post:

    $id = wp_insert_post($array);

    The post is well duplicated but without the rawHTML…

    I would be glad to read some ideas because I’m out of it.
    Thank you in advance,
    David

  • Unknown's avatar

    Hi there, I don’t see any WordPress.com website associated with this account you are using to post here in our community forums.

    Keep in mind that this support forum assists users with free websites hosted on the WPcom platform. WPcom (where we are ) and WP are separate entities with different documentation and support forums. More information about the differences can be found here: https://wordpress.com/support/com-vs-org/

    In case you need help with a site using the open source WP software, head over to https://wordpress.org/support/ where you’ll find documentation and users who have more experience with the software you are using. If you don’t have a username on the ORG forums you can register one on the top of that page.

  • The topic ‘Raw HTML and Raw JS emptied after duplicate’ is closed to new replies.