【发布时间】:2011-09-30 11:53:29
【问题描述】:
我想在我的 Web 服务器 (Apache 2.2) 上运行 Python CGI 脚本。当我尝试运行 test.py 文件时,出现以下错误:
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>403 Forbidden</title>
</head><body>
<h1>Forbidden</h1>
<p>You don't have permission to access /test.py
on this server.</p>
</body></html>
在错误日志中:
[client 127.0.0.1] Options ExecCGI is off in this directory: C:/Program Files (x86)/Apache Software Foundation/Apache2.2/htdocs/test.py
那么可能是什么问题?
【问题讨论】:
-
您无法在浏览器中运行 Python 脚本。您的意思是要在浏览器发出请求时在服务器上运行它们吗?