
			function submitForm(){
				var patterns = /^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/; 
			  	var email=document.getElementById("email").value;
				if(document.getElementById("gname").value==null ||document.getElementById("gname").value=="" ){
				alert("请填写姓名!");
				return;
				}
				if((patterns.test(email))){
				}else{
				alert("邮件格式有误！");
				return;
				}
				if(document.getElementById("checkNum").value==null||document.getElementById("gname").value=="" ){
				alert("请输入验证码!");
				return;
				}
				document.getElementById("form_message").submit();
			};
			
			function cancelForm(){
					document.getElementById("form_message");
			};
		 	
		 	function changeValidateCode(obj) {    
			//获取当前的时间作为参数，无具体意义
			var timenow = new Date().getTime();    
			//每次请求需要一个不同的参数，否则可能会返回同样的验证码    
			//这和浏览器的缓存机制有关系，也可以把页面设置为不缓存，这样就不用这个参数了。    
			obj.src="rand.action?d="+timenow;    
			} ;
			