009.get、post方法与HTTP协议之间的关系大揭秘

来源:互联网 发布:济南搜索引擎优化外包 编辑:程序博客网 时间:2024/06/05 11:51

1.get方法当做请求头访问

GET /test/login?username=”hello”&password=”123” HTTP/1.1

2.post 方法当做请求体访问

POST /test/login HTTP/1.1

Connection :keep -Alive

  Usrname=”hello”&possword=”123”

所以在浏览器中看到

get方法网址是http//test/login?username=”hello”&password=”123” 

Post方法网址是

http://test/login

3.通过浏览器进行文件上传时,一定要使用post方式而绝对不能使用get方式

4.通过浏览器地址栏输入网址的方式来访问服务器端资源,全部使用get方式

5.客户端、服务器与servlet/jsp之间的关系

 

6.

0 0
原创粉丝点击