日期:2014-05-16 浏览次数:20501 次
<script language="javascript"> function register(){ alert("in check script fun()"); var number=document.form1.number.value; var name=document.form1.name.value; var password=document.form1.password.value; var telephone=document.form1.telephone.value; var address=document.form1.address.value; if(number==""){ alert("准考证号不能为空,请输入!"); return false; } if(name==""){ alert("考生姓名不能为空,请输入!"); return false; } if(password==""){ alert("请准确输入你的密码!"); return false; } if(telephone==""){ alert("电话不能为空,请输入!"); return false; } if(address==""){ alert("地址不能为空,请输入!"); return false; } var radioElement=document.getElementsByName("identity"); <%int role=0;%> for(i=0;radioElement.length;i++) { if(radioElement.checked) { if(i==0) <% role=1;%>; else <% role=0;%>; break; } } <% System.out.println(role); if(dbl==null) dbl=new DbLink(); //boolean result=dbl.userAdd(00); //String.valueOf(request.getParameter("number")),String.valueOf(request.getParameter("name")),String.valueOf(request.getParameter("password")),String.valueOf(request.getParameter("telephone")),String.valueOf(request.getParameter("address")),role //System.out.println(result); %> } </script>