Home >Web Front-end >JS Tutorial >How to build the simplest web server using python

How to build the simplest web server using python

一个新手
一个新手Original
2017-09-27 10:38:123766browse

First make sure that the python installation and environment configuration are complete, and then find the location of the html file through DOS commands.
Enter the following on the command line:

python -m http.server 8888

----------(8888为端口号,也可设置为其它)

In this way, a simple Web server is built. Enter

localhost:8888

in the browser to access via IP address

The above is the detailed content of How to build the simplest web server using python. 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