G
G
gerales2021-07-19 14:36:19
User navigation
gerales, 2021-07-19 14:36:19

How to make a dropdown item in wordpress custom menu?

Greetings . please tell me who understands. Is in the menu header

$menu =	wp_nav_menu( [
                'theme_location'  => 'menu_1',
                'menu'            => '', 
                'container'       => '', 
                'container_class' => '', 
                'container_id'    => '',
                'menu_class'      => 'nav__menu', 
                'menu_id'         => '',
                'echo'            => false,
                'fallback_cb'     => 'wp_page_menu',
                'before'          => '',
                'after'           => '',
                'link_before'     => '',
                'link_after'      => '',
                'items_wrap'      => '<ul  class="%2$s">%3$s</ul>',
              ] );


I want one menu item to open, in the admin panel I add a sub-item to the item, and it is displayed under the parent. How can I make it drop down. maybe the items_wrap argument needs to be changed, and if so, how?. not found anywhere. Tell me please

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question