HTML 使用表单标签实现注册页面的实例代码

文章主要介绍了HTML 使用表单标签实现注册页面的实例代码,需要的朋友可以参考下

案例说明:   

- 使用表格实现页面效果
- 超链接不想要有效果,使用href="#"
- 如果表格里面的单元格没有内容,使用空格作为占位符  
- 使用图片标签提交表单 <input type="image" src="图片的路径"/>
 

完整代码:

  1. <html>
  2.     <head>
  3.         <title>World</title>
  4.     </head>
  5.     <body>
  6.         <form action="01-hello.html" method="post">
  7.             <h3 align="center">欢迎登录此页面!</h3>
  8.             <table width="100%">
  9.                 <tr>
  10.                     <td align="right">注册邮箱:</td>
  11.                     <td><input type="text" name="regit"/></td>
  12.                 </tr>
  13.                 <tr>
  14.                     <td>&nbsp;</td>
  15.                     <td>您还可以使用<a href="#">手机号</a>注册或者使用<a href="#">账号</a>注册</td>
  16.                 </tr>
  17.                 <tr>
  18.                     <td  align="right">创建密码:</td>
  19.                     <td><input type="password" name="pwd"/></td>
  20.                 </tr>
  21.                 <tr>
  22.                     <td  align="right">真实姓名:</td>
  23.                     <td><input type="text" name="realname"/></td>
  24.                 </tr>
  25.                 <tr>
  26.                     <td  align="right">性别:</td>
  27.                     <td>
  28.                         <input type="radio" name="sex" value="famale"/>女
  29.                         <input type="radio" name="sex" value="male"/>男
  30.                     </td>
  31.                 </tr>
  32.                 <tr>
  33.                     <td  align="right">生日:</td>
  34.                     <td>
  35.                         <select name"year">
  36.                             <option value="1997"/>1997
  37.                             <option value="1998"/>1998
  38.                             <option value="1999"/>1999
  39.                         </select>年
  40.                         <select name"month">
  41.                             <option value="01"/>01
  42.                             <option value="02"/>02
  43.                             <option value="03" selected="selected"/>03
  44.                         </select>月
  45.                         <select name"day">
  46.                             <option value="20"/>20
  47.                             <option value="21"/>21
  48.                             <option value="22"/>22
  49.                         </select>日
  50.                     </td>
  51.                 </tr>
  52.                 <tr>
  53.                     <td  align="right">我现在:</td>
  54.                     <td>
  55.                         <select name"now">
  56.                             <option value="study"/>正在上学
  57.                             <option value="1998"/>已经工作
  58.                         </select>
  59.                     </td>
  60.                 </tr>
  61.                 <tr>
  62.                     <td>&nbsp;</td>
  63.                     <td><img src="images/verycode.png"/><a href="#">看不清换一张?</a></td>
  64.                 </tr>
  65.                 <tr>
  66.                     <td>&nbsp;</td>
  67.                     <td><input type="image" src="images/btn.png"></td>
  68.                 </tr>
  69.             </table>
  70.         </form>
  71.     </body>
  72. </html>

总结

以上所述是小编给大家介绍的HTML 使用表单标签实现注册页面的实例代码,希望对大家有所帮助。