Coding-Spot

You are not connected. Please login or register

 
 
 

Auto Navbar Selector

Message (Page 1 of 1)

#1

Nathan Adhitya

avatar
 
Advance Member

Posted May 31st 2013, 9:35 pm

 

*
THANKED

I made this by myself
i even haven't tested it LMFAO
Code:
$(document).ready(function(){
if (location.pathname == "/forum"){
$('#nav_app_forums').addClass('active');
}
if (location.pathname == "/faq"){
$('#nav_app_faq').addClass('active');
}
if (location.pathname == "/memberlist"){
$('#nav_app_members').addClass('active');
}
if (location.pathname == "/profile?mode=editprofile"){
$('#nav_app_profile').addClass('active');
}
if (location.pathname == "/privmsg?folder=inbox"){
$('#nav_app_mailbox').addClass('active');
}
if (location.pathname == "/privmsg?folder=sentbox"){
$('#nav_app_mailbox').addClass('active');
}
else if (location.pathname == "/privmsg?folder=outbox"){
$('#nav_app_mailbox').addClass('active');
}
});
I Made this specially for you mr.Mark
:D
I Like This Forum Sign





#2

Mark

Mark
 
Administrator
Administrator

Posted June 1st 2013, 11:51 am

 
They're working fine but there are other times that the class is not applied on some places even if the url is there alr.
Will try to get it work, but thanks anyway! Laugh



https://coding-spot.darkbb.com


Message (Page 1 of 1)

Similar topics

-

» Black Navbar

Permissions in this forum:
You cannot reply to topics in this forum

In total there is 0 user online :: 0 Registered, 0 Hidden and 0 Guests

Users browsing this forum: None