Skip to content

Instantly share code, notes, and snippets.

@ezos86
Created June 16, 2015 17:53
Show Gist options
  • Save ezos86/d67cb94bf396c2b2f092 to your computer and use it in GitHub Desktop.
Save ezos86/d67cb94bf396c2b2f092 to your computer and use it in GitHub Desktop.
Sample Read More to Try on Wordpress
<?php
$args = array(
'meta_key'=>'readmoretext',
'meta_value'=>'Go check this out',
'post_status'=>'publish',
'post_type'=>'post',
'orderby'=>'date',
'order'=>'DESC'
);
query_posts($args):
if(have_posts()) : while (have_posts()) : the_post();
//Do Whatever
endwhile; else:
//Do Whatever
endif;
wp_reset_query();
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment