
function validateForm(){
	var a = document.forms[1].elements[0].value;
	var b = document.forms[1].elements[1].value;
	var c = document.forms[1].elements[2].value;


	if((a == "noSelection") || (b == "noSelection") || (c == "noSelection"))
	{
		window.alert("You must make a selection for each option to obtain a quote.");
		return false;
	}
	return true;

}

function validateUpload(){

	var errorFound = 0;
	var errorList = "The following errors were found:\n\n";

	if (document.forms[2].elements[0].value == "")
	{
		errorFound = 1;
		errorList += "\tYou must enter your name.\n";
	}

	if (document.forms[2].elements[1].value == "")
	{
		errorFound = 1;
		errorList += "\tYou must enter a contact name in your company.\n";
	}

	if (document.forms[2].elements[2].value == "")
	{
		errorFound = 1;
		errorList += "\tYou must enter your company name.\n";
	}

	if (document.forms[2].elements[3].value == "")
	{
		errorFound = 1;
		errorList += "\tYou must enter your phone number.\n";
	}

	if (document.forms[2].elements[6].value == "")
	{
		errorFound = 1;
		errorList += "\tYou must enter your street address.\n";
	}

	if (document.forms[2].elements[7].value == "")
	{
		errorFound = 1;
		errorList += "\tYou must enter your suburb or town.\n";
	}

	if (document.forms[2].elements[9].value == "")
	{
		errorFound = 1;
		errorList += "\tYou must enter your postcode.\n";
	}

	if (document.forms[2].elements[10].value == "")
	{
		errorFound = 1;
		errorList += "\tYou must enter your email address.\n";
	}

	if (document.forms[2].elements[11].value == "")
	{
		errorFound = 1;
		errorList += "\tYou must select the file to be uploaded.\n";
	}

	if (document.forms[2].elements[13].value == "")
	{
		errorFound = 1;
		errorList += "\tYou include a description of the job details.\n";
	}

	if (document.forms[2].elements[15].value == "")
	{
		errorFound = 1;
		errorList += "\tYou must let us know when you require the job by.\n";
	}

	if (document.forms[2].elements[16].value == "")
	{
		errorFound = 1;
		errorList += "\tWho should the delivery be attentioned to?\n";
	}

	if (document.forms[2].elements[17].value == "")
	{
		errorFound = 1;
		errorList += "\tWhat is the contact nuber for the delivery?\n";
	}

	if (document.forms[2].elements[18].value == "")
	{
		errorFound = 1;
		errorList += "\tYou must provide us with the delivery address.\n";
	}

	if (document.forms[2].elements[20].value == "")
	{
		errorFound = 1;
		errorList += "\tWe require a postcode to confirm your address.\n";
	}

	if (errorFound == 1)
	{
		errorList += "\nPlease address these issues and re-submit your job.\n";
		alert(errorList);
		return false;
	}

	return true;
}

