$(
	function()
	{
		$(".ClassQuoteRequestSubmit").click(
			function()
			{
				var YourName	=	$("input#YourName").val();
				if( (YourName == "") ||  (YourName == "Your name (mandatory)") )
				{
					alert("Please insert the name correctly.");
					$("input#YourName").focus();
					return false;
				}
				var CompanyName	=	$("input#CompanyName").val();
				if( CompanyName == "Company name" )
				{
					CompanyName	=	"";
				}
				var CompanyLocation	=	$("input#CompanyLocation").val();
				if( CompanyLocation == "Company location" )
				{
					CompanyLocation	=	"";
				}
				var EmailAddress	=	$("input#EmailAddress").val();
				if( (EmailAddress == "") || (EmailAddress == "E-mail address (mandatory)") )
				{
					alert("Please insert a valid email.");
					$("input#EmailAddress").focus();
					return false;
				}
				if( Validate_Email_jquery(EmailAddress,"Please insert a valid email address.") == false )
				{
					$("input#EmailAddress").focus();
					return false;
				}
				var PhoneNumber	=	$("input#PhoneNumber").val();
				if( (PhoneNumber == "") ||  (PhoneNumber == "Phone number (mandatory)") )
				{
					alert("Please insert the phone number correctly.");
					$("input#PhoneNumber").focus();
					return false;
				}
				var Industry	=	$("input#Industry").val();
				if( Industry == "Industry" )
				{
					Industry	=	"";
				}
				var CompanySize	=	$("input#CompanySize").val();
				if( CompanySize == "Company size" )
				{
					CompanySize	=	"";
				}
				var BudgetRange	=	$("input#BudgetRange").val();
				if( BudgetRange == "Budget range" )
				{
					BudgetRange	=	"";
				}
				var CompetitorWebsite	=	$("textarea#CompetitorWebsite").val();
				if( CompetitorWebsite == "What's is your competitor's website" )
				{
					CompetitorWebsite	=	"";
				}
				var ProjectDescription	=	$("textarea#ProjectDescription").val();
				if( (ProjectDescription == "") ||  (ProjectDescription == "Provide us a brief description of your project's goals and ideas (mandatory)") )
				{
					alert("Please insert the project description correctly.");
					$("textarea#ProjectDescription").focus();
					return false;
				}
				var dataString	=	'YourName='+YourName+'&CompanyName='+CompanyName+'&CompanyLocation='+CompanyLocation+'&EmailAddress='+EmailAddress+'&PhoneNumber='+PhoneNumber+'&Industry='+Industry+'&CompanySize='+CompanySize+'&BudgetRange='+BudgetRange+'&CompetitorWebsite='+CompetitorWebsite+'&ProjectDescription='+ProjectDescription;
				$.ajax(
					{
						type: "POST",
						url: "ajax_quote_request.php",
						enctype: 'multipart/form-data',
						data: dataString,
						success: function(html)
						{
							$('#quote_request_form').html("<div id='message'></div>");
							$('#message').html("<h2>Quote request Form Submitted!</h2><p>We will be in touch soon.</p>").hide().fadeIn(500);
						}
					}
				);
				return false;
			}
		);
	}
);

