'mystique', 'description' => esc_html__( 'Displays your categories, tags, most commented posts and recent comments in a tabbed interface.', 'mystique' ), ), array( 'width' => 300, 'height' => 350, 'id_base' => 'mystique-widget' ) ); } /** * The actual widget display */ function widget( $args, $instance ) { extract( $args ); /* Widget settings variables */ $title = apply_filters('widget_title', $instance['title'] ?? null ); $show_categories = isset( $instance['show_categories'] ) ? $instance['show_categories'] : false; $show_tags = isset( $instance['show_tags'] ) ? $instance['show_tags'] : false; $show_archives = isset( $instance['show_archives'] ) ? $instance['show_archives'] : false; $show_most_commented = isset( $instance['show_most_commented'] ) ? $instance['show_most_commented'] : false; $show_recent_comments = isset( $instance['show_recent_comments'] ) ? $instance['show_recent_comments'] : false; $show_post_count = isset( $instance['show_post_count'] ) ? $instance['show_post_count'] : false; $sort_categories = $instance['sort_categories'] ?? null; $num_most_commented = $instance['num_most_commented'] ?? null; $num_recent_comments = $instance['num_recent_comments'] ?? null; /* Before widget */ echo $before_widget; ?>
'', 'num_most_commented' => '10', 'num_recent_comments' => '8', 'sort_categories' => 'name', 'show_post_count' => true, 'show_categories' => true, 'show_tags' => true, 'show_archives' => true, 'show_most_commented' => true, 'show_recent_comments' => true ); $instance = wp_parse_args( (array) $instance, $defaults ); ?>
id="get_field_id( 'show_categories' ) ); ?>" name="get_field_name( 'show_categories' ) ); ?>" />
id="get_field_id( 'show_tags' ) ); ?>" name="get_field_name( 'show_tags' ) ); ?>" />
id="get_field_id( 'show_archives' ) ); ?>" name="get_field_name( 'show_archives' ) ); ?>" />
id="get_field_id( 'show_most_commented' ) ); ?>" name="get_field_name( 'show_most_commented' ) ); ?>" />
id="get_field_id( 'show_recent_comments' ) ); ?>" name="get_field_name( 'show_recent_comments' ) ); ?>" />
id="get_field_id( 'show_post_count' ) ); ?>" name="get_field_name( 'show_post_count' ) ); ?>" />