Need help with creating menu with wp_get_nav_menu_items hook
-
Hello !
I need help to creating a very custom menu with wp_get_nav_menu_items hook.
I want to create a sub menu to a existant one, with sub sub menu inside. The sub menu work correctly but when I want to add sub sub menu to a sub menu, they are not placed below but after the menu.
I use that to create item of my menu :
$new_item = new stdClass; $new_item->menu_item_parent = $parent; $new_item->ID = random_int(1000, 9999); $new_item->url = $url; $new_item->title = $title; $new_item->menu_order = $order;
I think is the menu_order I don’t understand perfectly..
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Need help with creating menu with wp_get_nav_menu_items hook’ is closed to new replies.