In distinction fiddle get and post requests

Reference: ten steps to kill one person, thousands of miles without leaving the line

get and post requests

First, we look at these two requests what it is, what are the characteristics of

1, get used to obtain data from the server, post is used to transfer data to the server

2, get the data in the form added in the form of key-value pairs to the rear url action is directed by? Connector and a connection between each variable &

   post is in the form of data stored in the body form data, variables and values ​​in accordance with a corresponding manner, the transfer action is directed url

3, get is unsafe because url during transmission, the data is placed in the request, but now many existing server, proxy server, or the user agent will request url to the log file, and then placed in a place, so there may be some privacy information being viewed by third parties. Further, the user can directly see the data submitted in the browser, some systems with internal message will be displayed in front of the user

     All operations of a post is not visible

4, get a small amount of transmission, mainly because by the url length limit

     post can transmit large amounts of data, it can only be used in post upload files

5, limit values ​​get form the form of a data set must be ascll character

     post iso10646 support the entire character set

6, get a form default method

 

get request

Here we can see the request header in the request headers is get type.

 get request is not the request parameters.

Raw get request parameters of view, is divided into three parts

1, the request url

2, host address (URL request)

3, the request header headers

 

post request

This is a post request, the general post request is the need to manually input information, I use here login post request.

 post has a body member, you can store data.

 Compared to get, we see post one more body body, to let us enter the phone number and password, authentication code and so on.

 

Guess you like

Origin www.cnblogs.com/cheneyboon/p/11525323.html
Recommended