Highlighting the left menu of the current SharePoint page

I have discovered that it is in fact quite simple and effective:

function highlightCurrentMenu() {
var As = document.getElementsByTagName("A");

for (var i=0; i
if (As[i].className == "zz2_QuickLaunchMenu_1 ms-navitem zz2_QuickLaunchMenu_5") {
if (As[i].href == document.location) {
As[i].style.fontWeight = "bold";
As[i].parentNode.style.backgroundColor = "#dddddd";

Spread the word. Share this post!

Leave A Reply

Your email address will not be published. Required fields are marked *