• Resolved dkurapati

    (@dkurapati)


    Yesterday I have received an email saying that there is an issue with content control plugin. Below are error details :

    An error of type E_ERROR was caused in line 153 of the file
    /var/www/wordpress/wp-content/plugins/content-control/classes/Models/RuleEngine/Rule.php.
    Error message: Uncaught Exception: Rule epkb_post_type_1_all has no
    callback. in /var/www/wordpress/wp-content/plugins/content-control/classes/Models/RuleEngine/Rule.php:153
    Stack trace:
    #0 /var/www/wordpress/wp-content/plugins/content-control/classes/Models/RuleEngine/Rule.php(136):
    ContentControl\Models\RuleEngine\Rule->run_check()
    #1 /var/www/wordpress/wp-content/plugins/content-control/classes/Models/RuleEngine/Query.php(100):
    ContentControl\Models\RuleEngine\Rule->check_rule()
    #2 /var/www/wordpress/wp-content/plugins/content-control/classes/Models/RuleEngine/Group.php(71):
    ContentControl\Models\RuleEngine\Query->check_rules()
    #3 /var/www/wordpress/wp-content/plugins/content-control/classes/Models/RuleEngine/Query.php(102):
    ContentControl\Models\RuleEngine\Group->check_rules()
    #4 /var/www/wordpress/wp-content/plugins/content-control/classes/Models/Restriction.php(333):
    ContentControl\Models\RuleEngine\Query->check_rules()
    #5 /var/www/wordpress/wp-content/plugins/content-control/classes/Services/Restrictions.php(207):

    I am using

    Current plugin: Content Control (version 2.0.1)
    PHP version 7.4.3-4ubuntu2.19

    and also when I search for my website on Goggle I am getting Chinese characters . Can please help me with this?

    The page I need help with: [log in to see the link]

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author Daniel Iser

    (@danieliser)

    @dkurapati – Can you try installing v2.0.6 or later. I made some patches to try and address these situations.

    There are 2 possibilities if that doesn’t work:

    1. The plugin that creates that content type epkb_post_type_1 doesn’t register post types before the WP init action. We try to address this with a patch to prevent our code from checking until as late as possible which should have fixed this.
    2. You have another plugin/theme on your site querying posts before all the post types are registered (earlier than they probably should be, though that is out of our control ultimately). In this case we can give you some code to add that will help identify which plugin/theme/code is doing it, and hopefully then help set our plugin to ignore those queries. That should cause it to work correctly.
    Plugin Author Daniel Iser

    (@danieliser)

    @dkurapati – Oh I should add, we have updated the plugin to log a notice in these cases but not throw an error any longer, so you should be able to update to the latest version and not see that error.

    Thread Starter dkurapati

    (@dkurapati)

    Hi,

    I have updated the plugin version still I don’t see the posts getting reflected on the website. Generally on this page “https://cosmos.ualr.edu/blog/” all the post will be displayed I can see the posts on the backend but on the website they are not getting reflected? and when I search for my website on google I am getting characters in Chinese and it also says “The site may be hacked” can you help how to rectify this

    Plugin Author Daniel Iser

    (@danieliser)

    @dkurapati – Can you share your restriction protection method and content rules?

    Further if google is showing chinese content for your site, it likely means your site was compromised with malware some weeks ago as search results take time to update and we only pushed our plugin update this week. I can assure you these issues are not coming from our code, there are only latin based characters (english) in it.

    You might install a security scanner plugin like WP Vuln or Securi or Ithemes security or all of them one at a time and run scans.

    Thread Starter dkurapati

    (@dkurapati)

    Here is the image

    https://cosmos.ualr.edu/wp-content/uploads/2023/09/content-control.png

    • This reply was modified 2 years, 8 months ago by dkurapati.
    Plugin Author Daniel Iser

    (@danieliser)

    @dkurapati – Sorry for the delay, can you send me screens of the actual settings in your restriction, one of the last 2 tabs mainly (Protection & Content).

    Further if its possible can you follow this guide and send us a login token via the support form here

    Plugin Author Daniel Iser

    (@danieliser)

    @dkurapati – I just released a big update with fixes for a bunch of reported issues. Among them was allowing admins to delay query processing until a specific action.

    If your still seeing issues in v2.0.9, try adding the following snippet to your site (Code Snippets plugin works great).

    add_filter( 'content_control/query_filter_init_hook', function () {
        return 'init'; // Try setup_theme, after_theme_setup, init or wp_loaded
    } );

    This should prevent plugins that are querying before all your rules are registered from triggering issues with normal WP queries which you want the plugin to scan.

    You can play with the different actions listed in the comment to see which gives better results.

    Let us know.

    Plugin Author Daniel Iser

    (@danieliser)

    @dkurapati – Haven’t heard from you in a while, gonna mark this closed. If you are still having trouble feel free to mark this unresolved again and update us on the status.

    Otherwise please take a moment to rate & review the plugin and or support to spread the word.

Viewing 8 replies - 1 through 8 (of 8 total)

The topic ‘Control content Plugin issue’ is closed to new replies.