Skip to content

Instantly share code, notes, and snippets.

@kirasiris
Created October 24, 2017 01:02
Show Gist options
  • Save kirasiris/e2f47f378c5568c8ffb06564db956bd3 to your computer and use it in GitHub Desktop.
Save kirasiris/e2f47f378c5568c8ffb06564db956bd3 to your computer and use it in GitHub Desktop.
<?php $args = array(
'posts_per_page' => 5,
'offset' => 0,
'category' => '',
'category_name' => '',
'orderby' => 'date',
'order' => 'DESC',
'include' => '',
'exclude' => '',
'meta_key' => '',
'meta_value' => '',
'post_type' => 'post',
'post_mime_type' => '',
'post_parent' => '',
'author' => '',
'author_name' => '',
'post_status' => 'publish',
'suppress_filters' => true
);
$posts_array = get_posts( $args ); ?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment