[support] Apply CSS to Parent on a Hover State for a Child

Shai Gluskin shai at content2zero.com
Fri Feb 26 17:31:25 UTC 2010


Gang,

I'm using nice menus. Primary nav has a background for a hover state. Some
of the primary navs have children which are drop-downs as implemented via
Nice Menus.

The problem I am having is that I want the hover state for the primary nav
to stick when using the drop down. Right now, when you mouse down over the
dropdown links the hover state disappears.

The relevant css is:

#primary ul a {
 background-color: #ffffff;
}

#primary ul a:hover {
  background-color: #e7e7e7; // I want this declaration to stick, even when
the children are being hovered over!
}

#primary ul li ul li a {
  background-color: #e7e7e7;
}

#primary ul li ul li a:hover {
  color: #ffffff;
  background-color: #0f6cb6;
  }

Help would be much appreciated.

Shai
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.drupal.org/pipermail/support/attachments/20100226/37d7d62e/attachment.html 


More information about the support mailing list