function checkMediaForm(){		
	
	if (trim(document.mediaForm.companyName.value).length < 2){
		alert("Please enter the company name.");
		document.mediaForm.companyName.value = trim(document.mediaForm.companyName.value);
		document.mediaForm.companyName.focus();
		return false;
	}
	
	if (trim(document.mediaForm.mediaType.value).length < 2){
		alert("Please enter the media type.");
		document.mediaForm.mediaType.value = trim(document.mediaForm.mediaType.value);
		document.mediaForm.mediaType.focus();
		return false;
	}

	if (trim(document.mediaForm.physicalAddress.value).length < 2){
		alert("Please enter the full company address.");
		document.mediaForm.physicalAddress.value = trim(document.mediaForm.physicalAddress.value);
		document.mediaForm.physicalAddress.focus();
		return false;
	}
	
	if (trim(document.mediaForm.location.value).length < 2){
		alert("Please enter the name of the city in which the company resides.");
		document.mediaForm.location.value = trim(document.mediaForm.location.value);
		document.mediaForm.location.focus();
		return false;
	}
	
	if(trim(document.mediaForm.file.value).length > 0){
		if (!(/^[a-zA-Z]{1}\:\\.{1,}\.[jJgGpP][pPiInN][gGfF]$/.test(trim(document.mediaForm.file.value)))){
			alert("Please choose a valid JPG, GIF or PNG logo image.");
			document.mediaForm.file.value = trim(document.mediaForm.file.value);
			document.mediaForm.file.focus();
			return false;
		}
	}
	
	if (trim(document.mediaForm.narrative.value).length < 2){
		alert("Please enter the company narrative.");
		document.mediaForm.narrative.value = trim(document.mediaForm.narrative.value);
		document.mediaForm.narrative.focus();
		return false;
	}
	
	if (trim(document.mediaForm.productTitle.value).length < 2){
		alert("Please enter the product title.");
		document.mediaForm.productTitle.value = trim(document.mediaForm.productTitle.value);
		document.mediaForm.productTitle.focus();
		return false;
	}
	
	if (trim(document.mediaForm.tel.value).length < 2){
		alert("Please enter the company contact number.");
		document.mediaForm.tel.value = trim(document.mediaForm.tel.value);
		document.mediaForm.tel.focus();
		return false;
	}
	
	if (trim(document.mediaForm.fax.value).length < 2){
		alert("Please enter the company fax number.");
		document.mediaForm.fax.value = trim(document.mediaForm.fax.value);
		document.mediaForm.fax.focus();
		return false;
	}
	
	if (!(/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(trim(document.mediaForm.email.value)))){
		alert("Please enter a valid email address.\n");
		document.mediaForm.email.value = trim(document.mediaForm.email.value);
		document.mediaForm.email.focus();
		return false;
	}
	
	if (trim(document.mediaForm.web.value).length < 2){
		alert("Please enter the company website address.");
		document.mediaForm.web.value = trim(document.mediaForm.web.value);
		document.mediaForm.web.focus();
		return false;
	}

	if (!document.mediaForm.terms.checked){
		alert("Please verify that the information you have entered above is correct.");
		document.mediaForm.terms.focus();
		return false;
	}
	
	return true;
}