1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253 |
- <!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>
- <!-- 表单 action提交地址-->
- <form action="xxx">
- <!-- 文本框 type="text"-->
- 用户名:<input type="text">
- <!-- 密码框 type="password"-->
- 密码:<input type="password">
- <br>
-
- <!-- 单选框 type="radio" 需要有一个相同的name属性,代表他们是一组的-->
- 性别:
- <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>
- <!-- 下拉框 -->
- <select>
- <option>黑大</option>
- <option>理工</option>
- <option>林大</option>
- </select>
- <br>
- <!-- 文本域 -->
- <textarea></textarea>
- <br>
-
- <!-- 普通按钮 -->
- <button>按钮</button>
- <!-- type="submit" 提交按钮 -->
- <input type="submit">
- <!-- type="reset" 重置按钮 -->
- <input type="reset">
- </form>
-
- </body>
- </html>
|