browserName = navigator.appName;          
browserVer = parseInt(navigator.appVersion);

hasImageSupport = false;
relativePath2 = relativePath + "images/";
buttonName = new Array ('about','contact','estore','products','services');

for (var cnt=0; cnt < buttonName.length; cnt++) {
	eval ('var '+buttonName[cnt]+'_on = new Image();');
	eval (buttonName[cnt] + '_on.src = "'+relativePath2 + buttonName[cnt] + '_btn_on.gif"');
	eval ('var '+buttonName[cnt]+'_off = new Image();');
	eval (buttonName[cnt] + '_off.src = "'+relativePath2 + buttonName[cnt] + '_btn_off.gif"');
}	

if (browserName == "Netscape" && browserVer >= 3)
   hasImageSupport = true;
else if (browserVer > 3)
   hasImageSupport = true;

function buttonAction (imgName, isItOn) {   
  if (hasImageSupport) {
      if (isItOn) {	  
         document[imgName].src = eval(imgName + "_on.src");
      } else { 
            document[imgName].src = eval (imgName + "_off.src");
      }
   }
}


function validateEmail(formName)
{
	var myForm = eval('document.'+formName);
	var email = myForm["email"].value;
	var hasError = false;
	if (email=="")
		hasError = true;
	else if (email.indexOf("@") == -1) 
		hasError = true;
	else if (email.indexOf(".") == -1) 
		hasError = true;

	if (hasError)
	{
		alert ("Invalid e-mail address. Please try again.");
		return false;
	}
	else
		return true;
}