function setCurrentMenuItem()
{
	var menuLinksArray = document.getElementById("menuRoot").getElementsByTagName("a"); // Array of all links inside the menu
	for(var i=0; i < menuLinksArray.length; i++) // For each link inside the menuWrapper, ...
		if(menuLinksArray[i].href == window.location) // ... check if it is the same as the url of the current page
		{
			var currentMenuItem = menuLinksArray[i].className; // Read the className of the current menu item
			menuLinksArray[i].className = currentMenuItem + "current"; // and add "Current" to the this className
		}
}

if (window.addEventListener) //DOM method for binding an event (eg. FireFox)
window.addEventListener("load", setCurrentMenuItem, false)

else if (window.attachEvent) //IE exclusive method for binding an event (eg. Internet Explorer)
window.attachEvent("onload", setCurrentMenuItem)

else if (document.getElementById) //support older modern browsers
window.onload=setCurrentMenuItem
