URI: Uniform Resource Identifier Uri=url+urn
URL: Uniform Resource Locator
URN: Uniform Resource Name
The picture number above corresponds to the following number description:
1.HTTP (90% Market)/HTTPS/FTP Transmission Protocol (can be understood as express brother, is the medium of content transmission, through the transport protocol client can send some information to the server, the server can also pass the content to the client)
- HTTP: Hypertext Transfer Protocol, client and server side in addition to the transfer of text, but also can transfer pictures, audio and video and other rich media resources (binary file stream/base64 ...)
- HTTPS: More secure HTTP because his transmission channel is SSL-encrypted (basically the website that deals with money is the HTTPS transport protocol)
- FTP: Text upload protocol/resource File Transfer Protocol, often applied to the management of server resource files (upload/download ...)
2. Domain Name
- First-level domain name: www.qq.com (need to Buy), level two or three domain names need to be assigned to
- Level two domain name: sports.qq.com
- Level three domain name: kbs.sports.qq.com
3. Port number
- HTTP Default 80
- HTTPS default 443
- FTP Default 21
The port number value range 0~65535, the port number is occupied by a project/program, other programs will not be able to use this port number
4. Request the path and name of the resource file/students/index.html the index.html file under the current Project Students folder/index.html The index.html file is requested in the root directory of the current project, and when the request file is not specified, the resource file of the default request is generally/index.html or/default.html ()
5. Question Mark Xxx=xxx&xxx=xxx ...
- 1) The client can pass some information to the server by means of the question-mark parameter.
- 2) When you jump from the list page to the Details page, click on the list page of each record, will jump to the specified detail page, the details page shows the content is not the same, note: The details of the page is the same page, want to show the different content, you need to distinguish the click of which record, At this point we can pass the question mark in the way of the details page we get the parameter values passed, and then according to the mid is worth a different, from the server side to obtain a variety of data display can
6. Hash value (hash): #video
- 1) The client can also pass the information to the server in this way (but not generally)
- 2) Anchor point positioning
- 3) page routing switching via hash value
HTTP Things
- Request Requests Phase
- RESPONSE Response Phase
Both phases are completed, which is the completion of an HTTP thing
HTTP messages (the content sent to the server and the content returned to the client are collectively referred to as Messages)
- Start line
- Header: Request header, response header, Universal header (both request and response), custom header
- Principal: Request body, response body
Request Headers (header: Client settings, server-side fetch)
- get/getlist?_=0.19020438256316052 http/1.1-a request start line
- Request Header host:192.168.1.100:81
- Connection:keep-alive
- Cache-control:max-age=0
- user-agent:mozilla/5.0 (Windows NT 6.1; WOW64) applewebkit/537.36 (khtml, like Gecko) chrome/51.0.2679.0 safari/537.36
- Accept: /
- Referer: http://192.168.1.100:81/index.html
- Accept-encoding:gzip, deflate, SDCH
- accept-language:zh-cn,zh;q=0.8
Response Headers (response header: Server-side provisioning, client acquisition)
- http/1.1-OK response start line
- Content-type:application/json;charset=utf-8; Response header
- date:wed, 04:52:30 GMT server time for server-side return data
- Connection:keep-alive
- Transfer-encoding:chunked
Response Response Body
The content returned by the server can be seen in the response body (the content returned to the client by the server is essentially in the response body, and will, of course, be returned to the client in response headers depending on the requirements)
Request Payload Requests Body
If the client wants to deliver content to the server, it can be passed to the server in the request body, and the server receives the request to get the content in the request body
- The client can also pass some information to the server through the request header.
- The client also has a common way to pass information to the server: the way a question mark passes a parameter when a URL is requested
AJAX-related Request protocol