Programmatically toggle bootstrap 3 navigation bar

后端 未结 5 858
一整个雨季
一整个雨季 2021-01-18 13:16

I am using few items in my bootstrap 3 navigation bar grouped in like below:

5条回答
  •  日久生厌
    2021-01-18 13:51

    After a little bit of help from @Jahnux73 I figured it out myself. So the only thing I had to do is to add :

    data-toggle="collapse" data-target=".navbar-ex1-collapse"
    

    to the specific link that I wanted to toggle the navbar. so the link now looks like following:

    
         Go offline
    
    

提交回复
热议问题