WC_Widget::widget_start │ public │ WC 1.0

Output the html at the start of a widget.

Method of the class: WC_Widget{}

Hooks from the method

Returns

null. Nothing (null).

Usage

$WC_Widget = new WC_Widget();
$WC_Widget->widget_start( $args, $instance );
$args(array) (required)
Arguments.
$instance(array) (required)
Instance.

WC_Widget::widget_start() code WC 11.2.1

public function widget_start( $args, $instance ) {
	echo $args['before_widget']; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- Sidebar wrapper markup supplied by the theme via register_sidebar().

	$title = apply_filters( 'widget_title', $this->get_instance_title( $instance ), $instance, $this->id_base );

	if ( $title ) {
		echo $args['before_title'] . $title . $args['after_title']; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- Theme-supplied title wrappers around the widget_title filtered value.
	}
}