function formcheck() 
	{
	if (document.form1.business_type.value == "") 
        	{
        	alert("Please select your business type");
		form1.business_type.focus();
        	return false;
        	}
	if (document.form1.name.value == "") 
        	{
        	alert("Please enter your company name");
		form1.name.focus();
        	return false;
        	}
	if (document.form1.contact_first_name.value == "") 
        	{
        	alert("Please enter the contact's first name");
		form1.contact_first_name.focus();
        	return false;
        	}
	if (document.form1.contact_last_name.value == "") 
        	{
        	alert("Please enter the contact's last name");
		form1.contact_last_name.focus();
        	return false;
        	}
      if (document.form1.email.value.indexOf("@") == -1 || document.form1.email.value == "") 
      		{
        	alert("Please verify that you entered the e-mail address correctly");
		form1.email.focus();
	 	return false;
        	}       
	if (document.form1.address1.value == "") 
        	{
        	alert("Please enter the address");
		form1.address1.focus();
        	return false;
        	}
	if (document.form1.city.value == "") 
        	{
        	alert("Please enter the city");
		form1.city.focus();
        	return false;
        	}
	if (document.form1.state.value == "") 
        	{
        	alert("Please enter the state");
		form1.state.focus();
        	return false;
        	}
	if (document.form1.zip.value == "") 
        	{
        	alert("Please enter the zip/postal code");
		form1.zip.focus();
        	return false;
        	}
	if (document.form1.phone.value == "") 
        	{
        	alert("Please enter the phone number");
		form1.phone.focus();
        	return false;
        	}
	myOption1 = -1;
	for (i=0; i<document.form1.site_type.length; i++)
		{
 		if (document.form1.site_type[i].checked)
			{
  			myOption1 = i;
  	  		}
 		 }
 	if (myOption1 == -1)
		{
        	alert("Please select the type of site you would like");
		return false;
  		}
/*
	if (document.form1.client_supplied_domain.value == "")
		{
        	alert("Please enter your current Web site address");
		form1.client_supplied_domain.focus();
  		return false;
  		}
*/
 	if (document.form1.login.value == "") 
        	{
        	alert("Please enter a login name");
		form1.login.focus();
        	return false;
        	}     
	//	else
	//		{	
	//		var illegalChars = /\W/;
  	//		// allow only letters, numbers, and underscores
   	//		 if (illegalChars.test(login))
	//			{
      	//			alert("Make sure you only have letters and/or numbers in your login name \(no spaces or other characters\)");
        //			return false;
   	//			} 
	//		}
	if (document.form1.password.value == "") 
        	{
        	alert("Please select a password");
		form1.password.focus();
        	return false;
        	}
	//	else
	//		{	
	//		var illegalChars = /\W/;
  	//		// allow only letters, numbers, and underscores
   	//		 if (illegalChars.test(password))
	//			{
      	//			alert("Make sure you only have letters and/or numbers in your password \(no spaces or other characters\)");
        //			return false;
   	//			} 
	//		}
	if (document.form1.password.value != document.form1.retyped_password.value)
		{
		alert("Please make sure your retyped password is the same as your password");
		form1.retyped_password.focus();	
		return false;
		}

//	if (document.form1.site_type[0].checked==true || document.form1.site_type[1].checked==true) // site type with appts
//		{		
//		var Section_name = DOMGetElement("section1"); // get an object 
/*  	 
	if(document.form1.appt_method[0].name)
		{ 	
		myOption2 = -1;
		for (x=0; x<document.form1.appt_method.length; x++)
			{
 			if (document.form1.appt_method[x].checked)
				{
  				myOption2 = i;
  	 			}
 			}
 		if (myOption2 == -1)
			{
   		     	alert("Please select an appointment method");
			form1.appt_method.focus();	
  			return false;
			break;
			}
		}	
*/

//	if(document.form1.alternate_payment.checked == false)
//		{

/*
		if (document.form1.cc_type.value == "") 
	        	{
	        	alert("Please select a credit card type");
 	       	return false;
	        	}
		if (document.form1.cc_number.value == "") 
	        	{
 	       	alert("Please enter your credit card number");
 	       	return false;
 	       	}
		if (document.form1.cc_exp_month.value == "") 
 	       	{
 	       	alert("Please select your credit card expiration month");
 	       	return false;
	  	      	}
		if (document.form1.cc_exp_year.value == "") 
	        	{
	        	alert("Please select your credit card expiration year");
 	       	return false;
 	       	}

		if (document.form1.name_on_card.value == "") 
 	       	{
 	       	alert("Please enter the name on the credit card");
			form1.name_on_card.focus();
 	       	return false;
  		      	}

*/

//		myOption2 = -1;
//		for (i=0; i<document.form1.store_cc.length; i++)
//			{
// 			if (document.form1.store_cc[i].checked)
//				{
// 				myOption2 = i;
//  		  		}
//			 }

// 		if (myOption2 == -1)
//			{
//  		      	alert("Please select if you would like us to keep your credit card number on file");			
// 			return false;
//  			}
//		}
	if (document.form1.channel_id.value == "") 
        	{
        	alert("Please select how you heard about Appointment-Plus");
		form1.channel_id.focus();
        	return false;
        	}
	return true;
    }

function newwindow(URL, windowname) 
	{ 
	window.open(URL,windowname,'resizable=yes,scrollbars=yes,menubar=no,toolbar=no,status=no,width=750,height=500,screenX=15,screenY=15,left=15,top=15'); 
	} 

function hidesection(section) 
	{
	if (document.getElementById)
		{	
		// this is the way the standards work
		document.getElementById(section).style.visibility = "hidden";
			}
			else if (document.all)
				{
				// this is the way old msie versions work
				document.all[section].style.visibility = "hidden";
				}
				else if (document.layers)
					{
					// this is the way nn4 works
					document.layers[section].visibility = "hidden";
					}
    return true; 
 	} 

function showsection(section) 
	{
	if (document.getElementById)
		{	
		// this is the way the standards work
		document.getElementById(section).style.visibility = "visible";
			}
			else if (document.all)
				{
				// this is the way old msie versions work
				document.all[section].style.visibility = "visible";
				}
				else if (document.layers)
					{
					// this is the way nn4 works
					document.layers[section].visibility = "visible";
					}
    return true; 
 	} 