function validForm(regForm){
//checks for valid content
	isValid=true;
	var valString="";
	for(looper=0;looper<regForm.elements.length;looper++){
		valString+=regForm.elements[looper].value
		}
	if((regForm.first_name.value.length<2)&&isValid){
		alert("Please enter at least two characters for your first name");
		isValid=false;
		}
	if((regForm.last_name.value.length<2)&&isValid){
		alert("Please enter at least two characters for your last name");
		isValid=false;
		}
	if((regForm.company.value.length<2)&&isValid){
		alert("Please enter your business name in the Company field");
		isValid=false;
		}
	if(((regForm.email.value.length<2)||(regForm.email.value.indexOf(".")<1)||(regForm.email.value.indexOf("@")<1))&&isValid){
		alert("Please enter a valid, complete email address");
		isValid=false;
		}
	if((regForm.phone.value.length<2)&&isValid){
		alert("Please enter a telephone number where you can be reached during business hours.");
		isValid=false;
		}
	if((regForm.street.value.length<2)&&isValid){
		alert("You must enter an address where you recieve mail.");
		isValid=false;
		}
	if((regForm.city.value.length<2)&&isValid){
		alert("Please enter the city name where your mail is sent.");
		isValid=false;
		}
	return isValid;
}
/* This script and many more are available free online at The JavaScript Source :: http://javascript.internet.com Updated by: Mike Weiner :: http://www.wearebent.com  Original author: Eric King (eric_andrew_king@hotmail.com) Last Updated: May 2006

Notes: Some parameters are not cross-browser capable (e.g. fullscreen).
Browsers that do not support these abilities will ignore them.

Usage: The link is written as follows: 
onclick="newWindow(this.href, 'popup', 600, 500, 1, 1, 0, 0, 0, 1, 0);

Usage Description:
"this.href" refers to the URL given in the "a" tag; "'popup'" is the name of the popup window;
600 is the width of the popup window; 500 is the height of the popup window; the numbers that
follow designate whether a property is turned on ("1") or off ("0"), in this order:
scrollbars, resizable, menubar, toolbar, addressbar, statusbar, fullscreen
*/
<!--Popup Window code -->
function newWindow(a_str_windowURL, a_str_windowName, a_int_windowWidth, a_int_windowHeight, a_bool_scrollbars, a_bool_resizable, a_bool_menubar, a_bool_toolbar, a_bool_addressbar, a_bool_statusbar, a_bool_fullscreen) {
  var int_windowLeft = (screen.width - a_int_windowWidth) / 2;
  var int_windowTop = (screen.height - a_int_windowHeight) / 2;
  var str_windowProperties = 'height=' + a_int_windowHeight + ',width=' + a_int_windowWidth + ',top=' + int_windowTop + ',left=' + int_windowLeft + ',scrollbars=' + a_bool_scrollbars + ',resizable=' + a_bool_resizable + ',menubar=' + a_bool_menubar + ',toolbar=' + a_bool_toolbar + ',location=' + a_bool_addressbar + ',statusbar=' + a_bool_statusbar + ',fullscreen=' + a_bool_fullscreen + '';
  var obj_window = window.open(a_str_windowURL, a_str_windowName, str_windowProperties)
    if (parseInt(navigator.appVersion) >= 4) {
      obj_window.window.focus();
    }
}