Configure WordPress Trash

WordPress-Christmas-07Check out our 7th door of our Advent Calendar.

WordPress Trash will have it's premiere in version 2.9. Now you can move every content, comment, post, pages, media and link to trash. It's quite the same function as you know from other online applications or operating systems.

If you like to configure a special date of how long files should be kept in your trash, you can configure it in your wp-config.php.
define( 'EMPTY_TRASH_DAYS', 10 );

The default settings deletes your content after 30 days. If you don't want to use trash at all, just use the value 0.

define('EMPTY_TRASH_DAYS', 0);

Now there is no trash in your admin area available, and also no links to move files to your trash.

Comments are closed.

3 comments

  1. Antonie Potgieter

    Awesome, thank you for this tip! Another useful thing to note is that when a post is in the trash, its "post_status" in the "wp_posts" database table is set to "trash". All the best, Antonie

  2. sanaa

    thank you,

    in my case the problem with the trash is that the special properties of my post are lost when the post is in the trash,
    when restored, only title and content are restored and not the others !

    any idea please ?

One pingback

  1. WordPress 2.9 Final mit Bugfixes und neuen Features - wordpress, wordpress 2.9, update, blog, plugin - Vip-Chicks