	function countryFormat(countryCheck)
	{
		var dlState = document.getElementById("dState");
		var txtProvince = document.getElementById("dProvince");
		var lblZIP = document.getElementById("lblZip");
		var lblState = document.getElementById("lblState");
		if (countryCheck == "" || countryCheck=="USA")
		{
			lblZIP.innerHTML = "<b>Zip</b>";
			lblState.innerHTML = "<b>State</b>";
			lblPhone.innerHTML = "(FORMAT: XXX-XXX-XXXX)";
			txtProvince.style.display = 'none';
			dlState.style.display = '';
		}
		else
		{
			lblZIP.innerHTML = "<b>Postal Code</b>";
			lblState.innerHTML = "<b>Province</b>";
			lblPhone.innerHTML = "";
			txtProvince.style.display = '';
			dlState.style.display = 'none';
		}
		lblFax.innerHTML = lblPhone.innerHTML;
	}

	function updateCenter(icenterId, timeString)
	{
		window.location.href="./index.asp?cid=" + icenterId + "&uid=" + timeString;
	}
	
	function checkForm(thisForm)
	{
		var retVal = true;
		var errMessages = "";
		
		if (thisForm.txtNewCenterName.value == "")
			errMessages += "+ You must provide a center name.\r\n";
						
		if (thisForm.City.value == "")
			errMessages += "+ You must provide a center city.\r\n";
			
		if (thisForm.Province.value == "" && thisForm.Country.value != "USA" && thisForm.Country.value != "")
			errMessages += "+ You must provide a province.\r\n";
		
		var announceErrs = validateAnnouncements();
		if (announceErrs != "")
			errMessages += announceErrs;
		
		if (errMessages != "")
			retVal = false;
			
		if (!retVal)
			alert("Please fix the following errors:\r\n\r\n" + errMessages);
			
		return retVal;
	}

	function clearAnnouncement(formName, ifield){
		var myform = document.forms[0];
		eval(formName + ".a0" + ifield + ".value=''");
		eval(formName + ".a1" + ifield + ".value=''");
		eval(formName + ".a2" + ifield + ".value=''");
		eval(formName + ".a3" + ifield + ".value=''");
	}
	
	function testMapQuest()
	{
		var thisForm = document.forms[0];
		lineNum = thisForm.mapToAddressLine.value;
		
		var addr = thisForm.Address.value;
		if (lineNum == 2)
			addr = thisForm.Address2.value;
			
		window.open("http://www.mapquest.com/maps/map.adp?country=US&countryid=250&addtohistory="
					+ "&address=" + escape(addr)
					+ "&city=" + escape(thisForm.City.value)
					+ "&state=" + escape(thisForm.State.value)
					+ "&zipcode=" + escape(thisForm.ZIP.value)
					+ "&submit=Get+Map","MapQuest","");
	}	