Created
June 7, 2013 01:09
-
-
Save josesayago/5726399 to your computer and use it in GitHub Desktop.
This is an example of embedding Single Latest Posts into a WordPress Template file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Check if the plugin has been activated | |
if( function_exists( 'single_latest_posts' ) ) { | |
/** | |
* Custom parameters | |
* Set only those you want to use | |
*/ | |
$parameters = array( | |
'title' => 'Luxury', | |
'title_only' => 'false', | |
'number_posts' => 3, | |
'custom_post_type' => 'cars', | |
'category' => 'luxury', | |
'category_link' => 'true', | |
'category_ltitle' => 'More on Luxury', | |
'css_style' => 'myslposts' | |
); | |
// Execute | |
single_latest_posts( $parameters ); | |
} | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment