widget_cssclass = 'widget_product_search'; $this->widget_description = __( 'Shows a search-box in a widget which lets you search products based text entered.', 'ajaxify-filters' ); $this->widget_id = 'ccas_ajax_product_search'; $this->widget_name = __( 'AJAX Product Search', 'ajaxify-filters' ); $this->settings = array( 'title' => array( 'type' => 'text', 'std' => __( 'Search Products', 'ajaxify-filters' ), 'label' => __( 'Title', 'ajaxify-filters' ) ) ); parent::__construct(); } /** * Output widget. */ function widget( $args, $instance ) { if ( ! is_post_type_archive( 'product' ) && ! is_tax( get_object_taxonomies( 'product' ) ) ) { return; } $this->widget_start( $args, $instance ); ?>