Home  >  Article  >  Backend Development  >  How to set php port

How to set php port

王林
王林Original
2020-08-01 15:12:387263browse

How to set the php port: 1. Use a text editing tool to open the \apache\conf\httpd.conf configuration file; 2. Find the "Listen 80" configuration in the configuration file; 3. Modify the port according to your own needs Just use the number, such as 8080.

How to set php port

First use the editing tool to open the \apache\conf\httpd.conf file;

(Recommended tutorial: php Graphic tutorial)

Then find the following configuration in the file:

# Change this to Listen on specific IP addresses as shown below to
# prevent Apache from glomming onto all bound IP addresses.
#
#Listen 12.34.56.78:80
Listen 80 #修改这里

(Video tutorial recommendation: php video tutorial)

Finally Just modify the port number as needed, such as 8080.

When accessing, enter "http:/localhost:modified port number" in the browser.

How to set php port

The above is the detailed content of How to set php port. For more information, please follow other related articles on the PHP Chinese website!

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