====== 差别 ======
这里会显示出您选择的修订版和当前版本之间的差别。
后一修订版 | 前一修订版 | ||
前端基础_html_form.md [2021/09/15 14:30] admin 创建 |
前端基础_html_form.md [2021/09/15 15:31] (当前版本) admin |
||
---|---|---|---|
行 1: | 行 1: | ||
- | < | ||
[\<\< 返回HTML教程](: | [\<\< 返回HTML教程](: | ||
- | </markdown> | + | |
+ | ## 标签概览 | ||
+ | ``` | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | < | ||
+ | <div class=" | ||
+ | <input type=" | ||
+ | <form action="/ | ||
+ | <div class=" | ||
+ | < | ||
+ | </ | ||
+ | <div class=" | ||
+ | <label for=" | ||
+ | <input id=" | ||
+ | </ | ||
+ | <div class=" | ||
+ | <label for=" | ||
+ | <input id=" | ||
+ | </ | ||
+ | <div class=" | ||
+ | < | ||
+ | <input type=" | ||
+ | <input type=" | ||
+ | <input type=" | ||
+ | </ | ||
+ | <div class=" | ||
+ | < | ||
+ | <input type=" | ||
+ | <input type=" | ||
+ | </ | ||
+ | <div class=" | ||
+ | <input type=" | ||
+ | </ | ||
+ | <div class=" | ||
+ | <select name=" | ||
+ | <option value=" | ||
+ | <option value=" | ||
+ | <option value=" | ||
+ | </ | ||
+ | </ | ||
+ | <div class=" | ||
+ | < | ||
+ | | ||
+ | </ | ||
+ | <input type=" | ||
+ | <input type=" | ||
+ | <input type=" | ||
+ | <input type=" | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | |||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | ``` | ||
+ | ## post vs get | ||
+ | - 1. 表象不同,get把提交的数据url可以看到,post看不到 | ||
+ | - 2. 原理不同,get 是拼接 url, post 是放入http 请求体中 | ||
+ | - 3. 提交数据量不同,get最多提交1k数据,浏览器的限制。post理论上无限制,受服务器限制 | ||
+ | - 4. get提交的数据在浏览器历史记录中,安全性不好 | ||
+ | - 5. 场景不同,get 重在 " | ||
+ | |||
+ | |||
+ | ## form标签属性 | ||
+ | |||
+ | - action: 表单提交的地址 | ||
+ | - method:提交保单的方法 | ||
+ | - target:在何处打开action | ||
+ | - enctype: | ||
+ | - application/ | ||
+ | - text/ | ||
+ | - multipart/ | ||
+ | |||
+ | ## CSRF | ||
+ | - [CSRF 是什么? | ||
+ | |||
+ | ## 参考阅读 | ||
+ | - [http methods](http:// | ||
+ |