Grow your CSS skills. Land your dream job.

Jquery drop down menu make ul stay selected

  • # May 3, 2012 at 7:42 am

    Hello everyone,

    I am developing a website with jquery drop down menus.

    I have the ul in a horizontal menu with text links once hovered the link is highlighted with a background color & drop down pops up. But if i move my mouse down on teh drop down menu links the top link is no longer highlighted.

    is there a way to make teh top links stay highlighted with background color even when i move my cursor down to the links in drop down?

    Would appreciate some help.

    # May 3, 2012 at 8:22 am

    Simply give the parent anchor element a class of active or current and when you roll off simply remove that class, easiest way to do it.

    # May 8, 2012 at 11:24 pm

    that’s done with simple css:
    http://jsfiddle.net/F8xDT/

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".