1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465 |
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta charset="UTF-8">
- <meta http-equiv="X-UA-Compatible" content="IE=edge">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title>Document</title>
- </head>
- <body>
- <!-- 表单 -->
- <form action="后台提交地址">
- <!-- 文本框 type="text" -->
- 用户名:
- <input type="text">
- <!-- 换行 -->
- <br>
- <!-- 密码框 type="password" -->
- 密码:
- <input type="password">
- <br>
- <!-- 单选框 name属性="随便起"-->
- <!-- ctrl+? 注释 -->
- 性别:
- <input type="radio" name="sex">男
- <input type="radio" name="sex">女
- <br>
- <!-- 复选框 type="checkbox"-->
- 爱好:
- <input type="checkbox" name="hobby">吃饭
- <input type="checkbox" name="hobby">睡觉
- <input type="checkbox" name="hobby">敲代码
-
- <br>
- <!-- 下拉框
- 开始和结束标签中的内容是展示给用户看的
- value中的值是最终提交给后台,存在数据库中的
- -->
- 学校:
- <select>
- <option value="1">黑大</option>
- <option value="2">理工</option>
- <option value="3">农大</option>
- </select>
- <br>
- <!-- 文本域 -->
- 备注:
- <textarea></textarea>
- <br>
- <!-- 普通按钮 -->
- <input type="button" value="确定">
- <!-- 或 -->
- <button>确定</button>
- <!-- 提交按钮 type="submit" 提交按钮默认会提交表单 -->
- <input type="submit">
- <!-- 重置按钮 -->
- <input type="reset">
- </form>
-
- </body>
- </html>
|