_wp_reset_invalid_menu_item_parent


_wp_reset_invalid_menu_item_parent ( $menu_item_data )

Access:
  • private
Parameters:
  • (array) menu_item_data The menu item data array.
Returns:
  • (array) The menu item data with reset menu_item_parent.
Defined at:

Description

Prevents menu items from being their own parent.Resets menu_item_parent to 0 when the parent is set to the item itself. For use before saving `_menu_item_menu_item_parent` in nav-menus.php.

Related Functions

wp_setup_nav_menu_item, _wp_delete_tax_menu_item, wp_get_nav_menu_items, _wp_delete_post_menu_item, _is_valid_nav_menu_item

Top Google Results

User discussions

wpseek mobile