博客列表 >作业:注册表单

作业:注册表单

高如祥
高如祥原创
2022年10月18日 22:41:56467浏览

表单注册

  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8" />
  5. <meta http-equiv="X-UA-Compatible" content="IE=edge" />
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  7. <title>Document</title>
  8. </head>
  9. <body>
  10. <!-- !用户注册 -->
  11. <form action="register.php" method="post" enctype="application/x-www-form-urlencoded" onsubmit="return false">
  12. <fieldset>
  13. <legend>基本信息</legend>
  14. <div class="username">
  15. <label for="name">用户名</label>
  16. <input type="text" name="name" id="" required placeholder="用户名最少6个字符" />
  17. </div>
  18. <div class="password">
  19. <label for="">密&nbsp&nbsp&nbsp码</label>
  20. <input type="password" name="" id="" required />
  21. </div>
  22. <div class="age">
  23. <label for="">年龄</label><input type="number" name="" id="" />
  24. </div>
  25. <div class="time">
  26. <lable>生日</lable>
  27. <input type="date" name="" id="" min="1949-10-1" />
  28. </div>
  29. </fieldset>
  30. <fieldset>
  31. <legend>预置内容</legend>
  32. <div class="gender">
  33. <label for="secret">性别:</label>
  34. <input type="radio" name="gender" id="male" value="male" /><label for="male"></label>
  35. <input type="radio" name="gender" id="female" value="female" /><label for="female"></label>
  36. <input type="radio" name="gender" id="secret" value="secret" checked /><label for="secret">保密</label>
  37. </div>
  38. <div class="hobby">
  39. <lable>爱好:</lable>
  40. <input type="checkbox" name="" id="">游戏</input><input type="checkbox" name="" id="">item-2</input><input
  41. type="checkbox" name="" id="">item-3</input><input type="checkbox" name="" id="">item-4</input>
  42. </div>
  43. <div class="edu">
  44. <lable>学历</lable>
  45. <select name="edu" id="edu">
  46. <option value="" selected disabled>--请选择--</option>
  47. <optgroup label="中等教育">
  48. <option value="0">初中</option>
  49. <option value="1">高中</option>
  50. </optgroup>
  51. <optgroup label="高等教育">
  52. <option value="2">大专</option>
  53. <option value="3">本科</option>
  54. <option value="4">硕士</option>
  55. <option value="4">博士</option>
  56. </optgroup>
  57. </select>
  58. </div>
  59. <div class="like"><label for="">喜欢的编程语言</label>
  60. <input type="search" name="yuyan" list="detail" id="">
  61. <datalist id="detail">
  62. <option value="html">html</option>
  63. <option value="css">css</option>
  64. <option value="php"></option>
  65. <option value="c">c++</option>
  66. <option value="java">java</option>
  67. <option value="js">js</option>
  68. <option value="node">node</option>
  69. </datalist>
  70. </div>
  71. </fieldset>
  72. <button type="submit">提交</button>
  73. <button type="reset"></button>
  74. </form>
  75. </body>
  76. </html>
声明:本文内容转载自脚本之家,由网友自发贡献,版权归原作者所有,如您发现涉嫌抄袭侵权,请联系admin@php.cn 核实处理。
全部评论
文明上网理性发言,请遵守新闻评论服务协议