自己写的 http://www.onsrs.com/ajax/reg.asp 欢迎测试 !
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
<style type="text/css">
<!--
body,td,th {
font-family: 宋体;
font-size: 9pt;
}
-->
</style></head>
<body>
<form id="form1" name="thisForm" method="post" action="">
<table width="400" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#3399CC">
<tr>
<td width="96" height="26" bgcolor="#FFFFFF">用户名:</td>
<td width="304" bgcolor="#FFFFFF"> <input name="username" type="text" id="username" onBlur="validateField('username','required','username','errs1')" />
<span id="errs1" style="color:#FF0000">*</span></td>
</tr>
<tr>
<td height="26" bgcolor="#FFFFFF">密码:</td>
<td bgcolor="#FFFFFF"> <input name="password" type="password" id="password" onBlur="validateField('password','required','password','errs2')"/>
<span id="errs2" style="color:#FF0000">*</span></td>
</tr>
<tr>
<td height="26" bgcolor="#FFFFFF">重复密码:</td>
<td bgcolor="#FFFFFF">
<input name="repassword" type="password" id="repassword" onBlur="validateField('repassword','required','repassword','errs3')"/>
<span id="errs3" style="color:#FF0000">*</span></td>
</tr>
<tr>
<td height="26" bgcolor="#FFFFFF">密码提示问题:</td>
<td bgcolor="#FFFFFF">
<input name="what" type="text" id="what" onBlur="validateField('what','unrequired','what','errs4')" /> <span id="errs4" style="color:#FF0000"></span></td>
</tr>
<tr>
<td height="26" bgcolor="#FFFFFF">提示问题答案:</td>
<td bgcolor="#FFFFFF"> <input name="yes" type="text" id="yes" onBlur="validateField('yes','unrequired','yes','errs5')" /> <span id="errs5" style="color:#FF0000"></span></td>
</tr>
<tr>
<td height="26" bgcolor="#FFFFFF">姓名:</td>
<td bgcolor="#FFFFFF"> <input name="xingming" type="text" id="xingming" onBlur="validateField('xingming','unrequired','xingming','errs6')" /> <span id="errs6" style="color:#FF0000"></span></td>
</tr>
<tr>
<td height="26" bgcolor="#FFFFFF">身份证:</td>
<td bgcolor="#FFFFFF"> <input name="idcard" type="text" id="idcard" onBlur="validateField('idcard','unrequired','idcard','errs7')" /> <span id="errs7" style="color:#FF0000"></span></td>
</tr>
<tr>
<td height="26" bgcolor="#FFFFFF">联系电话:</td>
<td bgcolor="#FFFFFF"> <input name="phone" type="text" id="phone" onBlur="validateField('phone','unrequired','phone','errs8')" /> <span id="errs8" style="color:#FF0000"></span></td>
</tr>
<tr>
<td height="26" bgcolor="#FFFFFF">电子邮件:</td>
<td bgcolor="#FFFFFF"> <input name="email" type="text" id="email" onBlur="validateField('email','required','email','errs9')" />
<span id="errs9" style="color:#FF0000">*</span></td>
</tr>
<tr>
<td height="26" bgcolor="#FFFFFF">QQ:</td>
<td bgcolor="#FFFFFF"> <input name="qq" type="text" id="qq" onBlur="validateField('qq','unrequired','qq','errs10')" />
<span id="errs10" style="color:#FF0000"></span></td>
</tr>
<tr>
<td height="26" bgcolor="#FFFFFF">个人主页:</td>
<td bgcolor="#FFFFFF"> <input name="url" type="text" id="qq" onBlur="validateField('url','unrequired','url','errs11')" />
<span id="errs11" style="color:#FF0000"></span></td>
</tr>
<tr>
<td height="26" colspan="2" align="center" valign="middle" bgcolor="#FFFFFF"><input name="action" type="hidden" value="save" /> <input type="submit" name="Submit" value="提交" />
<input type="reset" name="Submit2" value="取消" /></td>
</tr>
</table>
</form>
</body>
</html>
本文展示了一个简单的用户注册表单HTML页面,其中包括了用户名、密码等基本信息的输入框,并设置了部分必填项验证。该示例适用于初学者了解基本的网页布局及表单验证。

被折叠的 条评论
为什么被折叠?



