(function(){	
	if(window.onload)	var oldOnLoad;
	window.onload=function(){
		if(oldOnLoad)	oldOnLoad();
		var frmObj=document.getElementById("go");
		if(!frmObj)	return;
		for(var i =0 ;i<frmObj.length;i++){
			if(frmObj[i].type=="select-one"){
				frmObj[i].onchange=function(){goto_url(this);};
			}
		}
	}
})();


// drop box menu navigation
function goto_url(selectMenu){ 
   var URL = selectMenu.options[selectMenu.selectedIndex].value;
   window.location.href = URL; 
   }
 
// old site design drop menus
function submenu_on(dept) {
	var litem = document.getElementById(dept);
	litem.style.display = "block";
	}
function submenu_off(dept) {
	var litem = document.getElementById(dept);
	litem.style.display = "none";
	} 
// hover action for 311 button in banner

upImage = new Image();
upImage.src = "https://www.springfield-ma.gov/typo3/images/311_City_Skyline-52h-mid.gif";
downImage = new Image();
downImage.src = "https://www.springfield-ma.gov/typo3/images/311_City_Skyline-52h-down.gif"
normalImage = new Image();
normalImage.src = "https://www.springfield-ma.gov/typo3/images/311_City_Skyline-52h-up.gif";

function changeImage()
{
  document.images["jsbutton"].src= upImage.src;
  return true;
}
function changeImageBack() 
{
   document.images["jsbutton"].src = normalImage.src;
   return true;
}
function handleMDown()
{
 document.images["jsbutton"].src = downImage.src;
 return true;
}
function handleMUp()
{
 changeImage();
 return true;
}


