#基本HTTP
python -m BaseHTTPServer 8080
如果目前目錄有index.html 則可以直接顯示
#簡單HTTP 包含GET與HEAD請求
python -m SimpleHTTPServer 8080
#HTTP 包含POST請求 目前
python -m CGIHTTPServer 8080
已sh腳本為CGI程式的語言 如下: 目前目錄下建立cgi-bin目錄
#!/bin/bash
echo "Content-Type: text/html" # HTML is following
echo ""
echo "<H1>This is my first CGI script</H1>"
echo "Hello, world!"
for((i=1;i<=100;i++))
do
echo $i
done