WordPress开发者和主题制作者的搜索引擎



wp_add_nav_menu_item ›

Since4.4.0
已弃用n/a
do_action( 'wp_add_nav_menu_item', $menu_id, $menu_item_db_id, $args )
参数: (3)
  • (int) $menu_id ID of the updated menu.
    Required: Yes
  • (int) $menu_item_db_id ID of the new menu item.
    Required: Yes
  • (array) $args An array of arguments used to update/add the menu item.
    Required: Yes
查看:
  • wp_update_nav_menu_item()
定义在:
文档:

Fires immediately after a new navigation menu item has been added.





源码

do_action( 'wp_add_nav_menu_item', $menu_id, $menu_item_db_id, $args );