
		function isEmpty (inputString) {
		
			if (inputString == null || inputString == "") {
				return true;
			}
			return false;
		}
		
		function isEmailAddr(email)
		{
		  var result = false
		  var theStr = new String(email)
		  var index = theStr.indexOf("@");
		  if (index > 0)
		  {
		    var pindex = theStr.indexOf(".",index);
		    if ((pindex > index+1) && (theStr.length > pindex+1))
			result = true;
		  }
		  return result;
		}
		
		function checkForm(form) {
			// Newsletter fields and story 1 fields are required
			if (isEmpty(form.Email.value)|| isEmpty(form.Lastname.value)|| isEmpty(form.Country.value)|| isEmpty(form.User9.value)|| isEmpty(form.Firstname.value)) {
				alert("\nPlease complete all required fields.\n" +
				      "Required fields for this form include:\n\n" +
					  "First Name, Last Name, Country,\n" +
					  "and Your Question for the Expert\n");
				return false;
			} else {
		   
		  		if (form.email.value.length < 3){
		       		alert("Please be sure to enter your correct email address in the \"email\" field.");
		     		form.email.focus();
					return (false);
		 		 }
		  return (true);
			}
			
			// Validation was successful...
			return true;
		}
		
		// Begin code for info windows.		
	
		function HideContent(d) {
		if(d.length < 1) { return; }
		document.getElementById(d).style.display = "none";
		}
		function ShowContent(d) {
		if(d.length < 1) { return; }
		document.getElementById(d).style.display = "block";
		}
		function ReverseContentDisplay(d) {
		if(d.length < 1) { return; }
		if(document.getElementById(d).style.display == "none") { document.getElementById(d).style.display = "block"; }
		else { document.getElementById(d).style.display = "none"; }
		}
		
		// Begin code for "Check All Checkboxes at Once"
		
		function checkUncheckAll(theElement) {
     	var theForm = theElement.form, z = 0;
	 	for(z=0; z<theForm.length;z++){
      	if(theForm[z].type == 'checkbox' && theForm[z].name != 'checkall'){
	  	theForm[z].checked = theElement.checked;
	  	}
     	}
    	}
