The basic concept of HTTP protocol: Hypertext Transfer Protocol,
HTTP request:
The user loads the network data: the user sends the request data to the server through the client or the browser, the server receives the request information, responds, and returns the data requested by the user to the user.
There are several ways to request HTTP protocols, and there are two common ones: get requests and post requests
A GET request is a way to request data from a server,
A POST request is a way to submit data to the server, such as "User login", etc.
The HTTP request consists of two main parts: the HTTP request header and the HTTP request body. Only the request body is available for the POST request.
The requested parameters are in two forms 1. Placed behind the URL, 2, in the request body
HTTP response:
The HTTP response consists of two parts: The response header, the response content
The HTTP response has a status code that indicates the response result for example: 200 for success, 404 for Page not found.
iOS Learning---http Protocol