Is there a method of displaying a post that is a draft when not logged in?

For example I have created a mailer template for my news...

if ( isset($_GET["mailer"]) )
get_template_part( 'mailers/template', 'news' );
else {
get_header(); ?>

    <!-- WEB TEMPLATE -->

<?php get_footer();
} ?>

This is on my single-news.php template.

As you can see my news mailer template is pulled in when I use this variable... ?mailer


But I would like to be able to still use the mailer template even when in draft mode.

Is this possible with adding a variable like this.. ?mailer&draft=true

I understand the 404 template is retrieved, and this may cause issues. Just wondering if there was a method I could adopt to get round this draft issue.


  • Please take a look at the code of this plugin and improve your question with what you've tried (instead of what task you're trying to solve). Thanks.
    – kaiser
    Nov 26, 2013 at 19:23
  • No thank you, this plugin is absolute perfect. Great thanks!
    – Joshc
    Nov 27, 2013 at 10:24


Browse other questions tagged or ask your own question.