WordPress.org

Support

Support » Plugins and Hacks » Revision Control » [Plugin: Revision Control] Complains that WP_POST_REVISIONS is defined and cannot operate

[Plugin: Revision Control] Complains that WP_POST_REVISIONS is defined and cannot operate

  • I’ve had this message for a while (I think since version 3) and today I decided to investigate. I checked my wp_config.php and WP_POST_REVISIONS was not defined. However I know it’s enabled by default, so I decided to set it to false. No luck either.

    So it seems no matter what I do, this plugin refuses to operate.

    http://wordpress.org/extend/plugins/revision-control/

Viewing 6 replies - 1 through 6 (of 6 total)
  • esmi

    @esmi

    Forum Moderator

    Perhaps WP_POST_REVISIONS has been defined by your theme. Try looking in the theme’s functions.php file. The plugin has worked without any problems for me on multiple WP 3.x sites.

    Unfortunately, I don’t seem to have a functions.php file in my theme.

    esmi

    @esmi

    Forum Moderator

    Really? That’s not impossible but it’s pretty unusual. Have you looked through all of your other theme files?

    Nah, I need to get home where I have shell access in order to run a grep. I’ll do that later.

    I have the same issue now. Did you resolve yours and if so, how?

    Thanks.

    Found the issue and fixed it. For anybody else that encounters a similar issue and does not want to (or cannot afford to) take the site offline and disable all the plugins to test, here’s what I did:

    1. After a fair amount of research, figured out that the attribute that determines whether the “Revisions” Meta Box shows in Screen Options is WP_POST_REVISIONS. This is set to “True” by default but, can be overridden in wp_config.php. More info here.

    2. Downloaded via FTP a copy of my entire web site. Using a text editor that can do a full-text search of *all* files (I used UltraEdit), I searched for WP_POST_REVISIONS.

    3. Found that it was being set to FALSE by a plugin – “postie” – on line 3 of postie-functions.php.

    4. Edited that file and commented out the line. Made a backup on my local system where I backup the few plugin files that I have had to override/hack so I can reapply my hacks after updating the plugin if needed. The first few lines of the file should look like this:

    <?php
    $revisions= WP_POST_REVISIONS;
    //define('WP_POST_REVISIONS', false);     <<-- Commented this line
    //define('POSTIE_DEBUG', true);
    if (!ini_get('safe_mode')) {

    And voila… The Revisions meta box is visible again for posts and pages.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘[Plugin: Revision Control] Complains that WP_POST_REVISIONS is defined and cannot operate’ is closed to new replies.
Skip to toolbar