关于 Content-Type:application/x-www-form-urlencoded 和 Content-Type:multipart/related
来源:互联网 发布:湖南软件职业学院地图 编辑:程序博客网 时间:2024/06/05 22:01
区别只是
Content-Type:application/x-www-form-urlencoded
和
Content-Type:multipart/related
查资料得:
application/x-www-form-urlencoded: 窗体数据被编码为名称/值对。这是标准的编码格式。 multipart/form-data: 窗体数据被编码为一条消息,页上的每个控件对应消息中的一个部分。 text/plain: 窗体数据以纯文本形式进行编码,其中不含任何控件或格式字符。
补充
form的enctype属性为编码方式,常用有两种:application/x-www-form-urlencoded和multipart/form-data,默认为application/x-www-form-urlencoded。 当action为get时候,浏览器用x-www-form-urlencoded的编码方式把form数据转换成一个字串(name1=value1&name2=value2...),然后把这个字串append到url后面,用?分割,加载这个新的url。 当action为post时候,浏览器把form数据封装到http body中,然后发送到server。 如果没有type=file的控件,用默认的application/x-www-form-urlencoded就可以了。 但是如果有type=file的话,就要用到multipart/form-data了。浏览器会把整个表单以控件为单位分割,并为每个部分加上Content-Disposition(form-data或者file),Content-Type(默认为text/plain),name(控件name)等信息,并加上分割符(boundary)。
- 关于 Content-Type:application/x-www-form-urlencoded 和 Content-Type:multipart/related
- 关于 Content-Type:application/x-www-form-urlencoded 和 Content-Type:multipart/related
- 关于 Content-Type:application/x-www-form-urlencoded 和 Content-Type:multipart/related
- 关于 Content-Type:application/x-www-form-urlencoded 和 Content-Type:multipart/related
- 关于 Content-Type:application/x-www-form-urlencoded 和 Content-Type:multipart/related
- 关于 Content-Type:application/x-www-form-urlencoded 和 Content-Type:multipart/related
- 关于 Content-Type:application/x-www-form-urlencoded 和 Content-Type:multipart/related
- 关于 Content-Type:application/x-www-form-urlencoded 和 Content-Type:multipart/related
- 关于 Content-Type:application/x-www-form-urlencoded 和 Content-Type:multipart/rel (2
- Content-Type的application/x-www-form-urlencoded和multipart/related
- Content-Type:application/x-www-form-urlencoded 和 Content-Type:multipart/rel
- Content-Type:application/x-www-form-urlencoded 和 multipart/form-data
- Content-Type: application/x-www-form-urlencoded
- 关于Content-Type中application/x-www-form-urlencoded 和 multipart/form-data的区别及用法
- 关于 Content-Type:application/x-www-form-urlencoded
- [转]Content-Type: application/x-www-form-urlencoded
- Content-Type: application/x-www-form-urlencoded什么意思
- Form content types(表单内容类型)--application/x-www-form-urlencoded和multipart/form-data
- Log4j配置文件以及配置方法
- Head First 设计模式——观察者模式(Observer Pattern)——Python实现(3)
- mysql客户端命令无法连接
- 大小端模式
- iis安装心得
- 关于 Content-Type:application/x-www-form-urlencoded 和 Content-Type:multipart/related
- Python IDE 测评
- 拉杂勒死
- 如何删除Internet临时文件 清理Cookies 清理缓存文件
- HTTP session原理及应用
- access2003数据库连接
- 为ProgressDialog 设置button编号
- ISS建站如何远程访问
- IncrediBuild 30天试用过期破解清零工具