Setting anchor link color for single page applications with SammyJS -
i have following navigation structure in sammyjs app.
<div id="sidebar-left" class="col-lg-2 col-sm-1"> <input type="text" id="txt-search-items" class="search hidden-sm" placeholder="search..." /> <div class="nav-collapse sidebar-nav collapse navbar-collapse bs-navbar-collapse"> <ul class="nav nav-tabs nav-stacked main-menu"> <li class="parent"> <a href="#/link1"><i class="fa fa-dashboard"></i><span class="hidden-sm">link 1</span></a> </li> <li class="parent"> <a class="dropmenu" href="#link2"><i class="fa fa-list-ul"></i><span class="hidden-sm">link 2</span></a> <ul class="child"> <li><a class="submenu" href="#/link2/sublink"><i class="fa fa-eye"></i><span class="hidden-sm">sub link</span></a></li> </ul> </li> <li class="parent"> <a class="dropmenu" href="#link3"><i class="fa fa-archive"></i><span class="hidden-sm">link 3</span></a> <ul class="child"> <li><a class="submenu" href="#/link3/sublink1"><i class="fa fa-eye"></i><span class="hidden-sm">sublink 1</span></a></li> <li><a class="submenu" href="#/link3/sublink2"><i class="fa fa-eye"></i><span class="hidden-sm">sublink 2</span></a></li> </ul> </li> <li class="parent"> <a class="dropmenu" href="#/link4"><i class="fa fa-user"></i><span class="hidden-sm">link 4</span></a> <ul class="child"> <li><a class="submenu" href="#/link4/sublink1"><i class="fa fa-eye"></i><span class="hidden-sm">sublink 1</span></a></li> <li><a class="submenu" href="#/link4/sublink2"><i class="fa fa-eye"></i><span class="hidden-sm">sublink 2</span></a></li> <li><a class="submenu" href="#/link4/sublink3"><i class="fa fa-eye"></i><span class="hidden-sm">sublink 3</span></a></li> </ul> </li> <li class="parent"> <a class="dropmenu" href="#/administration"><i class="fa fa-cogs"></i><span class="hidden-sm">link 5</span></a> <ul class="child"> <li><a class="submenu" href="#/link5/sublink1"><i class="fa fa-eye"></i><span class="hidden-sm">sublink 1</span></a></li> <li><a class="submenu" href="#/link5/sublink2"><i class="fa fa-eye"></i><span class="hidden-sm">sublink 2</span></a></li> <li><a class="submenu" href="#/link5/sublink3"><i class="fa fa-eye"></i><span class="hidden-sm">sublink 3</span></a></li> <li><a class="submenu" href="#/link5/sublink4"><i class="fa fa-eye"></i><span class="hidden-sm">sublink 4</span></a></li> <li><a class="submenu" href="#/link5/sublink5"><i class="fa fa-eye"></i><span class="hidden-sm">sublink 5</span></a></li> <li><a class="submenu" href="#/link5/sublink6"><i class="fa fa-eye"></i><span class="hidden-sm">sublink 6</span></a></li> </ul> </li> </ul> </div> </div>
i trying set anchor links background color on active click, doesn't seem working :a
because of use of #
. ideas?
Comments
Post a Comment