WP_Widget::_set
Sets the internal order number for the widget instance.
Method of the class: WP_Widget{}
No Hooks.
Returns
null. Nothing (null).
Usage
$WP_Widget = new WP_Widget(); $WP_Widget->_set( $number );
- $number(int) (required)
- The unique order number of this widget instance compared to other instances of the same class.
Changelog
| Since 2.8.0 | Introduced. |
WP_Widget::_set() WP Widget:: set code WP 6.9.1
public function _set( $number ) {
$this->number = $number;
$this->id = $this->id_base . '-' . $number;
}