'aude_latestpost_widget', 'description' => __('A widget for add recent posts with image thumbnails', 'aude_theme') ); /* Widget control settings. */ $control_tws = array( 'width' => 200, 'height' => 250, 'id_base' => 'aude_latestpost_widget' ); /* Create the widget. */ parent::__construct( 'aude_latestpost_widget', __('Audemedia ++ Latest Posts','aude_theme'), $widget_tws, $control_tws ); } /* ---------------------------------------------------------------------*/ /* Display widget /* -------------------------------------------------------------------- */ function widget( $args, $instance ) { extract( $args ); $title = apply_filters('widget_title', $instance['posttitle'] ); $postnumber = $instance['postnumber']; echo $before_widget; if ( $title ) echo $before_title . $title . $after_title; ?>
'', 'postnumber' => '5', ); $instance = wp_parse_args( (array) $instance, $defaults ); ?>