Home  >  Article  >  Web Front-end  >  What happens when you enter the URL from the browser and press Enter_html/css_WEB-ITnose

What happens when you enter the URL from the browser and press Enter_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 11:39:231072browse

After entering the URL in the browser and pressing Enter, what happens in the whole process? The whole process is very complicated if detailed in detail. I will briefly describe the whole process

1. Query DNS and obtain the IP address corresponding to the domain name

(1). The browser searches its own DNS cache

(2 ), search the DNS cache of the operating system

(3), read the local HOST file

(4), initiate a DNS system call

(4.1), The broadband operation server checks its own cache

(4.2), the operator server initiates an iterative DNS resolution request

2. After the browser obtains the IP address corresponding to the domain name, it initiates an HTTP three-way handshake

3. After the TCP/IP connection is established, the browser can send an HTTP request to the server

4. The server receives this request and generates HTML page code based on the path parameters and some back-end processing. Return to the browser

5. The browser gets the complete HTML page code and starts parsing and rendering. If it encounters referenced external JS, CSS, images and other static resources, they are also HTTP requests one by one. All need to go through the above steps

6. The browser renders the page according to the obtained resources, and finally presents a complete page to the user

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn