Skip to content

Instantly share code, notes, and snippets.

@mjangda
Created October 17, 2010 16:26
Show Gist options
  • Select an option

  • Save mjangda/630990 to your computer and use it in GitHub Desktop.

Select an option

Save mjangda/630990 to your computer and use it in GitHub Desktop.
Doing a WordPress loop with a custom status
<h3>Upcoming Posts</h3>
<ul>
<?php
global $post;
$myposts = get_posts( array( 'post_status' => 'queued' ) );
foreach($myposts as $post) : setup_postdata($post); ?>
<li><?php the_title(); ?></li>
<?php endforeach; ?>
</ul>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment