Turn Off Wordpress Revisions

24th February 2009 - 2 minutes read time

Wordpress has a nice little revisions feature that will allow you to revert to a previous version of a post if you don't like the current edit. However, the drawback of this feature is that it is not always needed and it fills the post table full of stuff you will never need. Fortunately, turning this feature off isn't too much of a pain. All you need to do is add the following line of code to your wp-config file, just below the DB_COLLATE line.

define('WP_POST_REVISIONS', 0);

You can also set the autosave interval here to something greater than the default of 60 seconds. It is possible to do this in the wp-config file since version 2.5.0.

define('AUTOSAVE_INTERVAL', 123);

If you want to get rid off all of the post revisions from your post table then you can use the following SQL query.

DELETE FROM wp_posts WHERE post_type = 'revision';



I often use wordpress, and sometimes could not set the interval autosaved but now thanks to your post, I know how to do it.

Bonnie (Tue, 02/24/2009 - 11:47)

Add new comment

The content of this field is kept private and will not be shown publicly.