Home  >  Article  >  Backend Development  >  web network request process_PHP version to be updated)

web network request process_PHP version to be updated)

WBOY
WBOYOriginal
2016-08-08 09:19:29946browse

When browsing and entering an address, how does it request the server and how does it display the page information?
Enter an http address in the browser, such as: http://localhost/
——>The browser will request the DNS server and obtain the corresponding IP address
——>Find the corresponding server (such as: Apache server) through the IP address
——>The server receives the request, parses the Url characters, and obtains the file path name after the IP address in the URL
——>1. Search the server's web directory to see if there are corresponding html, css, and xml files. If there are any, they will be returned directly to the browser. The browser will display the data returned by the parsing and display
——>2. If the requested PHP component is http://localhost/info.php, because Apache cannot handle it, it will be transferred to the PHP program for processing and then PHP will return the processing result to Apache in the form of html. , Apache returns it to the browser.

So, when installing Apache and PHP, you need to associate Apache with PHP. When Apache encounters a request for a php file, it will transfer it to the php program for processing.

Copyright Statement: This article is an original article. The source must be indicated when reprinting. The views in the article only represent the views at the time. There must be shortcomings. Welcome to remind me. Thank you very much!

The above introduces the web network request process (PHP version to be updated), including aspects of the content. I hope it will be helpful to friends who are interested in PHP tutorials.

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