<head>
<script language="javascript">
function checkon(){
yhm1=document.form2.yhm.value,
mm1=document.form2.mm.value,
mm11=document.form2.mm1.value,
xb1=document.form2.xb.value,
gx=document.form2.gxqm.value;
if(yhm1=="" || mm1=="" || mm11=="" || xb1=="" )
{
alert ("* 项目为必填");
return false;
}
else if(mm11!=mm1)
{
alert("两次密码输入 不一致");
return false;
}
else
return true;}
}
</script>
<style>
b{ color:#666666}
em{ font-style:normal; color:#CC3333}
</style>
</head>
<body bgcolor="#CCCCCC">
<center><caption><h2 >用 户 注 册</h2></caption>
<form action="zc1.asp" method="post" name="form2" >
<table width="350" height="184" border="1" cellpadding="0" cellspacing="0" >
<tr>
<td width="112" align="right"><b>用户名:</b></td>
<td width="8"> </td>
<td width="216" align="left"><input name="yhm" type="text" id="yhm" size="19" /> <em>*</em></td>
</tr>
<tr>
<td align="right"><b>密码:</b></td>
<td> </td>
<td align="left"><input name="mm" type="password" id="mm" size="20" /> <em>*</em></td>
</tr>
<tr>
<td align="right"><b>确认密码:</b></td>
<td> </td>
<td align="left"><input name="mm1" type="text" id="mm1" size="19" /> <em>*</em></td>
</tr>
<tr>
<td align="right"><b>性别:</b></td>
<td> </td>
<td align="left"><input type="radio" name="xb" value="radiobutton" />
<b>男</b>
<input type="radio" name="xb" value="radiobutton" />
<b>女</b> <em>*</em></td>
</tr>
<tr>
<td align="right"><b>个性签名:</b></td>
<td> </td>
<td align="left"><textarea name="gxqm" cols="18" rows="2" id="gxqm"></textarea></td>
</tr>
<tr>
<td colspan="3"><input type="submit" name="Submit" value="提交" onclick="return checkon()" />
<input type="reset" name="submit2" value="重填" /></td>
</tr>
</table>
</form>
</body>
调用函数 没效果