WC_Widget::__construct()
Constructor.
Метод класса: WC_Widget{}
Хуков нет.
Возвращает
null
. Ничего (null).
Использование
$WC_Widget = new WC_Widget(); $WC_Widget->__construct();
Код WC_Widget::__construct() WC Widget:: construct WC 8.7.0
public function __construct() { $widget_ops = array( 'classname' => $this->widget_cssclass, 'description' => $this->widget_description, 'customize_selective_refresh' => true, 'show_instance_in_rest' => true, ); parent::__construct( $this->widget_id, $this->widget_name, $widget_ops ); add_action( 'save_post', array( $this, 'flush_widget_cache' ) ); add_action( 'deleted_post', array( $this, 'flush_widget_cache' ) ); add_action( 'switch_theme', array( $this, 'flush_widget_cache' ) ); }