WP_Nav_Menu_Widget::__construct()
Sets up a new Navigation Menu widget instance.
Method of the class: WP_Nav_Menu_Widget{}
No Hooks.
Return
null
. Nothing (null).
Usage
$WP_Nav_Menu_Widget = new WP_Nav_Menu_Widget(); $WP_Nav_Menu_Widget->__construct();
Changelog
Since 3.0.0 | Introduced. |
WP_Nav_Menu_Widget::__construct() WP Nav Menu Widget:: construct code WP 6.5.2
public function __construct() { $widget_ops = array( 'description' => __( 'Add a navigation menu to your sidebar.' ), 'customize_selective_refresh' => true, 'show_instance_in_rest' => true, ); parent::__construct( 'nav_menu', __( 'Navigation Menu' ), $widget_ops ); }