Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Adding drop down on custom WP menu. Reply To: Adding drop down on custom WP menu.

#268055
Atelierbram
Participant

These navbars are some of the trickier things in webdesign, and to make it work on all devices, it was not a bad idea to take something existing that works and is well tested and integrate it with your custom navbar. But the problem with a dropdown in combination with the hover-effect “magic-nav” is the fact that the parent list-items can’t have a position of relative on them, or the magic-nav would not work. To solve this one can wrap the drop-down child list in a div with position relative applied.

https://codepen.io/atelierbram/pen/JLjNzy

I slightly adapted the CSS of [https://github.com/thednp/navbar.js](this thing) to work with alongside the CSS that is already there. Obviously this still needs a lot of work, for example the conflicting styles and implementation on mobile.