Manoj Maharana

Manoj Maharana

  • NA
  • 362
  • 127.5k

How do I make current menu item active in asp.net webforms m

Aug 17 2016 6:52 AM

How to current menu active

i.e. if i selected and go to that page then the dropdown menu need to active(

<li class="active treeview">

) in dynamically in asp .net c#.

I want by using jquery or javascript in c#.

All the leftside dropdown list are available in masterpage.

<li class="treeview" id="settingId" runat="server">
<a href="#">
<i class="fa fa-files-o"></i>
<span>SETTING</span>
</a>
<ul class="treeview-menu">
<li><a href=""><i class="fa fa-circle-o"></i>CATEGORY MANAGEMENT</a></li>
<li><a href=""><i class="fa fa-circle-o"></i>ADD CATEGORY</a></li>
<li><a href=""><i class="fa fa-circle-o"></i>EMAIL MANAGEMENT</a></li>
<li><a href=""><i class="fa fa-circle-o"></i>CHANGE PASSWORD</a></li>
</ul>
</li>
<li class="treeview" id="portfolioId" runat="server">
<a href="#">
<i class="fa fa-pie-chart"></i>
<span>PORTFOLIO</span>
<i class="fa fa-angle-left pull-right"></i>
</a>
<ul class="treeview-menu">
<li><a href=""><i class="fa fa-circle-o"></i>PROJECT MANAGEMENT</a></li>
<li><a href=""><i class="fa fa-circle-o"></i>ADD PROJECT</a></li>
<li><a href=""><i class="fa fa-circle-o"></i>PRODUCT MANAGEMENT</a></li>
<li><a href=""><i class="fa fa-circle-o"></i>ADD PRODUCT</a></li>
</ul>
</li>

Answers (10)