Dropdown Menu with Extra Code
-
I have been searching for a way to edit the code of my dropdown on wp_nav_menu. Below is what I am trying to do.
<nav class="main"> <div class"center"> <ul> <li>Menu Item 1</li> <ul> <div class="center"> <li class="dropdown">dropdown menu 1</li> <li class="dropdown">dropdown menu 1</li> </div> </ul> <li>Menu Item 2</li> <ul> <div class="center"> <li class="dropdown">dropdown menu 2</li> <li class="dropdown">dropdown menu 2</li> </div> </ul> </ul> <!-- Close main ul --> <div> <!-- Close main center --> </nav>
The nav container and center div is easy, but getting the center div in the dropdown is the challenge. I have been looking at a walker class but was sure if this is the right approach. I would like to do this without a plugin because of some of the custom coding. Has anyone else been able to do this? Thanks for any help!
Viewing 6 replies - 1 through 6 (of 6 total)
Viewing 6 replies - 1 through 6 (of 6 total)
- The topic ‘Dropdown Menu with Extra Code’ is closed to new replies.