Topic: Navbar Active Selections Not Working
Christopher Stuart asked 7 years ago
On my navbar, the active class is not working when a user selects a different menu item.
I was told that the active menu item should work automatically with bootstrap.
Can someone provide any clarification on this? I'm not sure if for some reason MDB is interfering with Bootstrap on this issue?
Thanks
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Status
Open
Specification of the issue
- User: Free
- Premium support: No
- Technology: General Bootstrap questions
- MDB Version: -
- Device: -
- Browser: -
- OS: -
- Provided sample code: No
- Provided link: No
Christopher Stuart commented 7 years ago
note i'm following this tutorial that uses this template---seems as this one is having the same issues? https://mdbootstrap.com/wp-content/themes/mdbootstrap4/content/jquery/tutorials/bootstrap/tutorial-1/3/index.html#Ollie Vincent pro commented 7 years ago
By default the bootstrap nav is html - and you need to manually add the active class on each page. If you want it to switch by itself such as adding a active class on click, then you will some JavaScript