How can I have a plugin (once installed) build a menu in the Appearance >> Menu area? I would like my plugin to make a menu called “office” and put 5 links on it. That way I can call that specific menu on a template the plugin installs.
Thanks in advance
PS I am not looking to build a menu item in the admin area. I want a navigation menu to be built in the APPEARANCE>>MENU area of the site.
You’re looking for
wp_update_nav_menu_object
andwp_update_nav_menu_item
.Check this WordPress Answers post for a working example.