How to Empty Trash Automatically After Some Day in WordPress

Hi friends, hope you are doing good. This is a very short tutorial about WordPress tips, this tips will help you more while developing WordPress websites.

If you want to delete all trash items automatically after a certain day from your WordPress websites, then this tutorial help you more, keep your close attention in this post as I am going to share how to empty trash automatically after some day in WordPress.

wordpress maintenance plugin list

How to Empty Trash Automatically After Some Day in WordPress

Open wp-config.php file from root directory of your website and copy paste below code snippet at the end of the file and save it. below code will automatically be deleted the trash items from your WordPress websites. It will work for WordPress posts and WordPress pages trash to empty automatically after you 5 days.

Hope this tutorial help you, if you have any WordPress related question, then add your comments in bellow comment section. I will be happy to answer your comments and also do like & share this article with your friends on social media also subscribe my blog to get all my new tips and tricks directly in your mail box.

If you like FreeWebMentor and you would like to contribute, you can write an article and mail your article to [email protected] Your article will appear on the FreeWebMentor main page and help other developers.

Recommended Posts:

Article Tags: , , , , , ,