/* -------------------------------------------- Hover Over Functions -------------------------------------------- */

		function initMenu(containerDiv, tagName)
		{
		/* Check we are dealing with IE */
			if (document.all && document.getElementById)
			{
				/* Deal with the main navigation */
				var nav = document.getElementById(containerDiv);
				if (nav)
				{
					var navItems = nav.getElementsByTagName(tagName);
					for (i = 0; i < navItems.length; i++)
					{
						var navItem = navItems[i];
						initElementHover(navItem);
					}
				}
			}
		}
		
		function initTags(hoverArray)
		{
			/* Check we are dealing with IE */
			if (document.all && document.getElementById)
			{
				for (i = 0; i < hoverArray.length; i++)
				{
					var element = document.getElementById(hoverArray[i]);
					initElementHover(element);					
				}
			}
		}
		
/* --------------------------------------------- Hover Core  */

		
		function initElementHover(element)
		{
			if (element)
			{
				element.onmouseover = function() {
				
					/* If there are other classes applied
					 * to the tag, add a space. Otherwise
					 * just set "hover" as the only class
					 */
					 
					if ("" != this.className) {
						this.className += ' '; 
					}
					
					this.className += 'hover'; 
				}
				
				element.onmouseout = function() {
				
					/* Check to see if hover is the only
					 * class applied to the tag. If so
					 * clear the whole class name.
					 * Otherwise search for " hover"
					 * and remove it.
					 */
					 
					if ("hover" == this.className) {
						this.className = ''; 
					} else {
						this.className = this.className.replace(' hover', ''); 
					}
				}
			}
		}
