Turn Off Automatic Trash Deletion?
My guess is – yes, you are stuck with exactly that. Checks for EMPTY_TRASH_DAYS seem to be hardcoded as condition for switching interface between trash and delete in several places.
My guess is – yes, you are stuck with exactly that. Checks for EMPTY_TRASH_DAYS seem to be hardcoded as condition for switching interface between trash and delete in several places.
You can use wp_delete_post. To get all posts with the “trash” status: $trash = get_posts(‘post_status=trash&numberposts=-1’); Then: foreach($trash as $post) wp_delete_post($post->ID, $bypass_trash = true);