Line 459: | Line 459: | ||
// select a page from the menu based on the id assigned to it and the current page name and add the class "current page" to make it change background color | // select a page from the menu based on the id assigned to it and the current page name and add the class "current page" to make it change background color | ||
+ | $(".active").removeClass("active"); | ||
$("#"+ wgPageName.substring(wgPageName.lastIndexOf("/")+1, wgPageName.length ) + "_page").addClass("active"); | $("#"+ wgPageName.substring(wgPageName.lastIndexOf("/")+1, wgPageName.length ) + "_page").addClass("active"); | ||
Revision as of 09:08, 14 July 2017