'Recent Posts', 'posts_number' => '5', 'order_by' => 'none', 'display_title' => 'true', 'display_date' => 'true', 'display_featured_image' => 'true', 'excerpt_length' => '120', 'filter' => 'recent', 'filter_cats' => '', 'filter_tags' => '' ); class lzPosts extends WP_Widget { function __construct() { $widget_options = array('description' => 'Advanced widget for displaying the recent posts or posts from the selected categories or tags.'); $control_options = array( 'width' => 400); $this->WP_Widget('lzPosts', '» Posts with Images', $widget_options, $control_options); } function widget($args, $instance){ global $post; extract( $args ); $title = apply_filters('widget_title', $instance['title']); ?> 0 ): foreach($posts as $p) { ?>
ID)); $day=$date[1]; $month=$date[0]; ?>
ID) ) { echo get_the_post_thumbnail($p->ID,array(56,56), array()); } ?> '.mb_substr(strip_tags( apply_filters('the_content', $p->post_content) ),0,$instance['excerpt_length']).'

'; ?>
Display Elements: value="true" /> Post Title
value="true" /> Thumbnail
value="true" /> Date
Filter: value="recent" /> Show Recent Posts

value="category" /> Show Posts from a sinle category:


value="cats" />
Category IDs ( e.g: 5,9,24 )


value="tags" />
Tag slugs ( e.g: computer,news,business-news )