Forums

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

Home Forums JavaScript [Solved] Bootstrap collapse menu stays open

  • This topic is empty.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #236580
    wolfgang1983
    Participant

    Each time I reload my page my bootstrap menu stays open.

    I only would like it to open when I click on the links.

    Why is it staying open when reload page and how could I solve this so it can stay closed until I click on the link.

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

    #236582
    Ilan Firsov
    Participant

    Change the

    <ul class="list-group" class="collapse" ... >
    

    to:

    <ul class="list-group collapse" ... >
    

    also change the aria-expanded attribute to false. Bootstrap’s JS should update it when expanding/collapsing but you should set it properly for the initial state

    #236583
    wolfgang1983
    Participant

    It works for the main system menu but now the user menu inside stays open. I only want to open and close when I click on it.

    #236584
    wolfgang1983
    Participant

    Solved Now

    Was the same problem as other menu

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