* @version 1.0.2 * @link http://wordpress.org/extend/themes/annarita * @package AurelioDeRosa * @subpackage Annarita * @since Annarita 1.0 * @license http://www.gnu.org/licenses/gpl-3.0.html GNU General Public License version 3 */ class Annarita_review_widget extends WP_Widget { public function __construct() { parent::__construct( 'annarita_review_widget', 'Annarita reviews', array('description' => __('This widget lets you to show your own reviews with the related image if provided', 'annarita')) ); } public function form($instance) { $title = isset($instance['title']) ? $instance['title'] : __('Reviews', 'annarita'); $number = isset($instance['number']) ? $instance['number'] : 5; ?>

$number, 'no_found_rows' => true, 'post_status' => 'publish', 'ignore_sticky_posts' => true, 'post_type' => 'annarita_review' )); if ($query->have_posts()) { echo $before_widget; if (!empty($title)) echo $before_title . $title . $after_title; echo '