WordPress.org

Forums

Wp-Insert
[resolved] wp-insert hijacking content (3 posts)

  1. erwpacc
    Member
    Posted 2 years ago #

    in this file:
    wp-insert/includes/legal-pages/content.php

    this filter:
    add_filter('the_content', 'wp_insert_legal_filter_the_content');

    is replacing my content with the privacy policy from this page:
    wp-insert/includes/legal-pages/data.php

    it appears as though the following conditional evaluates to true when an empty string is compared to an empty string:
    if(in_array($page_details['ID'], explode(',', $options['privacy-policy']['pages'])))

    http://wordpress.org/extend/plugins/wp-insert/

  2. namith.jawahar
    Member
    Plugin Author

    Posted 2 years ago #

    In the above code $page_details['ID'] will never be empty...Its the same as global $post; $post->ID. I am not sure whats happening in your particular installation. Do let me know any additional details you might have which might be contributing to the issue

  3. erwpacc
    Member
    Posted 2 years ago #

    sorry for the late reply, i have been on travel.

    two conditions need to be present for this to occur(at least as far as I have seen):

    1. I have only seen this happen for scheduled posts, maybe it has something to do with the way wp-cron publishes articles vs manually publishing.

    2. Another plugin needs to attempt to apply "the_content" filter. The problem shows when I use the WP Book Lite plugin.
    http://wordpress.org/extend/plugins/wpbook-lite/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.