Skip to content

Instantly share code, notes, and snippets.

@GitaStreet
Last active July 10, 2022 14:59
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save GitaStreet/b808c7ac08e8306c2b7b82dfcd6646e1 to your computer and use it in GitHub Desktop.
Save GitaStreet/b808c7ac08e8306c2b7b82dfcd6646e1 to your computer and use it in GitHub Desktop.
WordPress: Set number of post revisions and autosave interval
/**
* wp-config.php between these comments:
* /* Add any custom values between this line and the "stop editing" line. */
*
* /* That's all, stop editing! Happy publishing. */
*/
// Avoid database bloat with less revisions
define( 'WP_POST_REVISIONS', 1 );
// Time interval in seconds
define( 'AUTOSAVE_INTERVAL', 16000 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment