showing results for - "active menu adminlte 3 using jquery"
Iker
30 Jun 2019
1// AdminLTe 3.0.x
2/** add active class and stay opened when selected */
3  var url = window.location;
4
5// for sidebar menu entirely but not cover treeview
6  $('ul.nav-sidebar a').filter(function() {
7    return this.href == url;
8  }).addClass('active');
9
10// for treeview
11  $('ul.nav-treeview a').filter(function() {
12    return this.href == url;
13  }).parentsUntil(".nav-sidebar > .nav-treeview").addClass('menu-open').prev('a').addClass('active');