javascript - Bootstrap nav pills with / sign in the tab link don't works -


i'm using bootstrap nav pills. if put / sign link of tab, tab not work, throws javascript error in jquery own code if click it. how can fix this?

<ul class="nav nav-pills"> <li class="active"><a data-toggle="pill" href="#ax">first</a></li> <li><a data-toggle="pill" href="#b/x">second / sign</a></li> <li><a data-toggle="pill" href="#cx">third</a></li> </ul> 

jsfiddle

the character / special character, means have escape it.
adding \ in front of it.


your final code like:

<ul class="nav nav-pills">     <li class="active"><a data-toggle="pill" href="#ax">first</a></li>     <li><a data-toggle="pill" href="#b\/x">second / sign</a></li>     <li><a data-toggle="pill" href="#cx">third</a></li> </ul> 

Comments

Popular posts from this blog

sequelize.js - Sequelize group by with association includes id -

android - Robolectric "INTERNET permission is required" -

java - Android raising EPERM (Operation not permitted) when attempting to send UDP packet after network connection -