Skip to content

Instantly share code, notes, and snippets.

@BobaWebDev
Created December 13, 2017 21:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save BobaWebDev/81788f5eb85d622533b0c533e1b936c0 to your computer and use it in GitHub Desktop.
Save BobaWebDev/81788f5eb85d622533b0c533e1b936c0 to your computer and use it in GitHub Desktop.
// example 1 ( plain call )
the_essence_posts_list();
// example 2 ( with options )
the_essence_posts_list(
array(
'orderby' => 'date',
'order' => 'DESC',
'amount' => 8,
'columns' => 3,
'category' => array( 4, 5, 6 ),
)
);
// Check https://codex.wordpress.org/Class_Reference/WP_Query for more info on accepted values for orderby and order
// amount is simply the amount of posts you want to show
// columns is the amount of posts shown per row
// category accepts IDs in array form
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment