Forums

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

Home Forums JavaScript Bootstrap JS Menu Question

  • This topic is empty.
Viewing 1 post (of 1 total)
  • Author
    Posts
  • #195832
    wolfgang1983
    Participant

    When I click on a menu item in the dropdown-menu in bootstrap navbar. I would like the li .dropdown have a class active when I click on a sub menu link and make it stay.

    What’s the best way to do it in java script.

    Adds class to all links when click. I only would like it to add it which matches that parent.

    http://codepen.io/riwakawebsitedesigns/pen/VYQmrP

    http://codepen.io/riwakawebsitedesigns/pen/VYQmrP

Viewing 1 post (of 1 total)
  • The forum ‘JavaScript’ is closed to new topics and replies.