'allinone_featured_category_widget', 'description' => esc_html__('Displays categories and posts.', 'allinone'), 'customize_selective_refresh' => true, ); $fields = array( 'title_1' => array( 'label' => esc_html__('Title 1:', 'allinone'), 'type' => 'text', 'class' => 'widefat', ), 'post_category_1' => array( 'label' => esc_html__('Select Category 1:', 'allinone'), 'type' => 'dropdown-taxonomies', 'show_option_all' => esc_html__('All Categories', 'allinone'), ), 'title_2' => array( 'label' => esc_html__('Title 2:', 'allinone'), 'type' => 'text', 'class' => 'widefat', ), 'post_category_2' => array( 'label' => esc_html__('Select Category 2:', 'allinone'), 'type' => 'dropdown-taxonomies', 'show_option_all' => esc_html__('All Categories', 'allinone'), ), 'title_3' => array( 'label' => esc_html__('Title 3:', 'allinone'), 'type' => 'text', 'class' => 'widefat', ), 'post_category_3' => array( 'label' => esc_html__('Select Category 3:', 'allinone'), 'type' => 'dropdown-taxonomies', 'show_option_all' => esc_html__('All Categories', 'allinone'), ), ); parent::__construct('allinone-featured-category-layout', esc_html__('Allinone: Category Call to action Widget', 'allinone'), $opts, array(), $fields); } /** * Outputs the content for the current widget instance. * * @param array $args Display arguments. * @param array $instance Settings for the current widget instance. * @since 1.0.0 * */ function widget($args, $instance) { $params = $this->get_params($instance); echo $args['before_widget']; ?>