Revisions is one of the great feature in WordPress Content Management System. Revisions allows to maintain different versions of the post into the database. Whenever required we can restore the post from its revisions.
When Revisions feature is enabled, WordPress maintains all the revisions and their information into the database tables; which increase the database size and if number of posts and their revisions are more, obviously there will be a performance hit.
Unfortunately WordPress not provided an user interface to enable/disable revisions feature. But it allows to enable/disable this feature using some configuration settings.
In this article we will discuss on enabling or disabling Revisions feature in WordPress.
I hope you already aware that WordPress use “wp_config.php” file for configuration settings. These settings will control the behavior of WordPress and its components. This is one of the important file in WordPress installation. This file contains your website’s base configuration details, such as database connection details etc.,
Follow the below steps to enable or disable Post Revisions.
Step 1. Login into your site control panel (eg: cPanel).
Step 2. Open “File Manager” and go to the location where “wp_config.php” file exists.
Step 3. Open “wp_config.php” file in Code Editor.
Step 4. Check whether the entry WP_POST_REVISIONS is defined in “wp_config.php” file. Entries are defined using PHP’s define function.
If WP_POST_REVISIONS constant is not defined or edit the existing entry:
To enable revisions, place the below code into “wp_config.php” file.
To disable revisions, place the below code into “wp_config.php” file.
Step 5. Once you made the changes, save “wp_config.php” file.
Step 6. Login into your WordPress based website as an administrator.
Step 7. Start adding new posts, and observe the following:
When Revisions feature is enabled, you will see “Revisions:” field under Publish section in “Edit Post” page.
If Revisions feature is disabled, WordPress will not display “Revisions:” field and it is not allowed to maintain any revisions for the post.
Necessary cookies are absolutely essential for the website to function properly. This category only includes cookies that ensures basic functionalities and security features of the website. These cookies do not store any personal information.
Any cookies that may not be particularly necessary for the website to function and is used specifically to collect user personal data via analytics, ads, other embedded contents are termed as non-necessary cookies. It is mandatory to procure user consent prior to running these cookies on your website.