Turn off Post Revisions and Disable Auto Saves in WordPress

Do you Use post Revisions and auto saves in your WordPress Blog ? Does it solve any purpose ?  This tutorial describes how you can turn off the post revisions and post auto saves in wordpress.

Why you should Turn off Post revisions and Auto saves:

WordPress Post revisions and auto saves can be a pain.Here are the Reasons why you should consider disabling wordpress post revisions and auto saves :

1. Every Post revision writes the database and creates a new entry in the post_revisions table. Whenever you want to edit an earlier post the database is called and the post revisions is checked. This increases the time required for your post panel to load.

2. If you are the only writer in your blog then Post revisions is  not needed.

3. While writing a post “Auto-Saves” can be really irritating. In every 60 seconds the post panel Freezes performing an auto save.

Disable WordPress Auto saves:

To disable wordpress auto saves open your functions.php File and add the following lines

function disableAutoSave(){
    wp_deregister_script('autosave');
}
add_action( 'wp_print_scripts', 'disableAutoSave' );

You are done. Now whenever you are writing a post in WordPress post panel your posts will not be auto saved.If you want to later add the auto save feature just remove these lines from the functions.php file.

Disable post revisions:

If  You have a Single author blog  then  you should consider turning off post revisions.It doesn’t solve any purpose and may consume some database space and hence the complexity

To completely turn off post revisions in wordpress just add the following lines in your wp-config.php file

define('WP_POST_REVISIONS',false);

But wait ! Post revisions may be useful too:

Post revisions  are useful when you are facing a disaster. Consider a Situation :

You are editing an already Published post  and changed the content and saved it.Now that published post   Will contain the new content and the old content will be lost. Now if after a Few weeks you want to revert back to the Older content you are screwed. You can’t. You have completely lost the older content.In case you had the pst revisions feature turned on You could have restored the older content.

How do i Recover the Older content If I have Post revisions Off ?

Don’t give up. If Your blog is Indexed in the search engines then you need not worry. You can recover the older content from Google cache provided you  Know the Url of your article. Just type cache:your URL in the google search box and you can recover the older content.

Hope you found it useful. Turned off at your blog? Share with us! Happy Blogging!!

9 Responses to “Turn off Post Revisions and Disable Auto Saves in WordPress”

Leave a Reply

IMPORTANT! To be able to proceed, you need to solve the following simple math (so we know that you are a human) :-)

What is 13 + 10 ?
Please leave these two fields as-is: