Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

Dropdown menu coding - mouse over

  • 31-07-2014 04:51PM
    #1
    Registered Users, Registered Users 2 Posts: 3,063 ✭✭✭


    Hi All,

    I've a code snippet I'm trying to edit.

    My website has a link navigation dropdown menu in place, but the default setting it to activate it on a mouse click, not to function on mouse hover as I would prefer.

    Below is a snippet of the JS code - Anyone recommend a change to allow mouse hover to operate the dropdown?

    EDIT - I've added "hover" instead of "click" but it did not work...

    Thanks!


    $("#nav .navbar-nav > li .dropdown-toggle").click(function () {

    $(this).parent().toggleClass("open-nav")

    });



Comments

Advertisement