• Resolved 5:4

    (@5against4)


    HELP!

    According to me error_log, every few seconds i’m getting this error:

    PHP Warning: Constant WP_POST_REVISIONS already defined in /home/qignz46hah60/public_html/5against4/wp-config.php on line 93

    i’ve no idea why this has started (2 days ago), but my wordpress site keeps going down intermittently.

    i have not idea about any of this – please can anyone help?!

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

Viewing 13 replies - 1 through 13 (of 13 total)
  • Your website is not available with this link.

    Which WP-version do you use?

    Have you checked if the error-message also appears if you disable all plugins?

    Can you please post the content of the wp-config.php here? You should remove your database-credentials before you do it.

    Thread Starter 5:4

    (@5against4)

    The site keeps going down, so that explains why the link isn’t currently working.

    i’m using whatever’s the latest release of WP.

    i’m not able to disable any plugins at present as i can’t access the dashboard, as the site’s down.

    Which sections should i remove from the wp-config.php file? The MySQL settings and Authentication Unique Keys and Salts?

    First thing: please check in wp-config.php line 93. I guess the line looks like this:

    define( 'WP_POST_REVISIONS', 3 );

    Commented out:

    //define( 'WP_POST_REVISIONS', 3 );

    After this change your website should be available. You have than to check you had added this line und which plugin could have throw the error.

    If this change was not a solution, then post the contents of wp-config.php here as written. You are welcome to remove (or ‘xxxx’) all sensitive data in it, e.g. the database access data.

    Thread Starter 5:4

    (@5against4)

    Actually, line 93 (also the last line) is this:

    require_once(ABSPATH . ‘wp-settings.php’);/** Prevents endless revisions of posts!! **/define(‘WP_POST_REVISIONS’, false);

    Does this shed any light?

    Thread Starter 5:4

    (@5against4)

    Also, if i try to access my details on GoDaddy, it’s currently saying “We Can’t Access Your Account.” WTAF?!

    And i’m struggling a bit to access via FTP now. What on earth’s going on?!

    • This reply was modified 2 years, 9 months ago by 5:4. Reason: Extra info

    The value “false” for WP_POST_REVISIONS disables the post revisions in WordPress. I don’t know if this is what you want to do in your website. So I can’t judge why this line is there. I guess it was inserted manually. And its wrong inserted: the setting for WP_POST_REVISIONS has to be before wp-settings.php, not after it.

    To disable the setting change this line to simply:

    require_once(ABSPATH . 'wp-settings.php');

    Not more. Save the file. I think the website should be available after it.

    Thread Starter 5:4

    (@5against4)

    Thanks for that – i’ve made the change, and my website instantly came back to life again – for about 30 seconds (so maybe a coincidence) – and now it’s down again.

    EDIT: But those errors are no longer being generated in the error_log, so that’s something…

    • This reply was modified 2 years, 9 months ago by 5:4. Reason: Extra info

    Does the wp-config.php look like as you edited it? Without the removed line? Or is this line back in the file? If this has happened, my guess would be that a plugin you are using keeps adding this line.

    Next try: disable all plugins in your project. As you can not login in wp-admin you have to move or remove all directories in /wp-content/plugins/. You can to that via FTP: https://www.ads-software.com/support/article/ftp-clients/

    Tipp: note all directories you see and remove there so you can install the plugins later again with help of this names.

    Thread Starter 5:4

    (@5against4)

    Okay, i renamed the plugins directory – and the website came back to life. For a minute or two – now it’s down again. This is insane…

    • This reply was modified 2 years, 9 months ago by 5:4.

    Than ask you hoster for help. I have no other ideas.

    Thread Starter 5:4

    (@5against4)

    i’ve been speaking to them for the last 10 minutes, they’ve just said,

    “There is a issue with the server and my technical team is been working and once the issue the is been fixed you will get the email notification for you.”

    i’m hoping through the broken English that there’s a genuine problem at GoDaddy’s end and that they’re not just fobbing me off. i guess we’ll have to wait and see.

    Thread Starter 5:4

    (@5against4)

    Thanks a lot for your help @threadi, i really do appreciate it – even though this isn’t resolved yet, i’m trying to stay optimistic, and this forum is helping a bit!

    • This reply was modified 2 years, 9 months ago by 5:4.
    Thread Starter 5:4

    (@5against4)

    It looks like – strangely – the problem with my site going down stems back to Wordfence, in conjunction with some GoDaddy server issues. i’ve deactivated WordFence and the site hasn’t gone down since. Weird. Marking as resolved though.

Viewing 13 replies - 1 through 13 (of 13 total)
  • The topic ‘HELP!!! PHP Warning: Constant WP_POST_REVISIONS already defined’ is closed to new replies.