		function check(){
			var aa = $('#CompanyName').val();
			if(aa ==""){
			//alert("公司名称不能为空！");
			dialog("信息提示","text:公司名称不能为空!","200px","auto","text"); 
			return false;
			}
		}
		function check1(){
			var bb = $('#Industry').val();
			if(bb ==""){
			//alert("公司规模不能为空！");
			dialog("信息提示","text:公司规模不能为空!","200px","auto","text"); 
			return false;
			}
		}
		function check2(){
			var cc = $('#ContactPerson').val();
			if(cc ==""){
			//alert("联系人不能为空！");
			dialog("信息提示","text:联系人不能为空!","200px","auto","text"); 
			return false;
			}
		}
		function check3(){
			var dd = $('#Email').val();
			if(dd ==""){
			//alert("邮件不能为空！");
			dialog("信息提示","text:邮件不能为空!","200px","auto","text"); 			
			return false;
			}
		}
		function check4(){
			var ee = $('#Telephone').val();
			if(ee ==""){
			//alert("电话不能为空！");
			dialog("信息提示","text:电话不能为空!","200px","auto","text"); 
			return false;
			}
		}
function checkall(){
		if(check()==false){
		return false;
		}
		if(check1()==false){
		return false;
		}
		if(check2()==false){
		return false;
		}
		if(check3()==false){
		return false;
		}
		if(check4()==false){
		return false;
		}
		return true;
}

function postajax(){	
		var CompanyName =$('#CompanyName').val();
		var Industry = $('#Industry').val();
		var ContactPerson = $('#ContactPerson').val();
		var Email = $('#Email').val();
		var Telephone = $('#Telephone').val();
		var ChooseInquiryType = $('#ChooseInquiryType').val();
		var Comments = $('#Comments').val();
		var language = $('#language').val();
		if( checkall()==true ){
		$.ajax({
		type:"POST",
		url: "../../disney_admin/email/insert.php",//通过php获取远程信息,解决ajax跨域问题
		data:"CompanyName="+CompanyName+"&Industry="+Industry+"&ContactPerson="+ContactPerson+"&Email="+Email+"&Telephone="+Telephone+"&ChooseInquiryType="+ChooseInquiryType+"&Comments="+Comments+"&language="+language,//提交过去的参数 data ="id="+id+"&value="+value       

		success: function(str){ //str是php的返回值
				if(str=="success"){
					dialog("信息提示","text:感谢您的提交，我们会尽快与您联络!","200px","auto","text"); 
				}else
				{
					dialog("信息提示","text:网络繁忙，请稍后再试!","200px","auto","text"); 
				}
				 }
			});
		}
}
