Question

I have a superfish menu here and I would like the submenu to dropdown vertically. I can achieve this by setting

.sf-menu.sf-style-white.sf-navbar li ul {
  width: 150px;
  left: 100px;
}

However, this is not a flexible solution because it will only work if I only have 1 parent-item that has a submenu and I would have to adjust it manually depending on where in the menu the link is. I'm looking for a way to dropdown submenu's below their parent items automatically.

Was it helpful?

Solution

Add below properties to your rules. This will help you.

.sf-menu.sf-style-white.sf-navbar li {
    position:relative;
}

.sf-menu.sf-style-white.sf-navbar li ul {
    left: 0;
}
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top