Python 2.7.8标题前脚本输出结束:特比

2024-09-30 01:33:02 发布

您现在位置:Python中文网/ 问答频道 /正文

我使用的是Ubuntu 12.04,使用的是Vmware,我正在研究Python cgi-bin。我遵循这个教程:http://archive09.linux.com/feature/136602。我的example1.py "Hello, Linux.com!"打印成功,但example2.py没有成功打印,服务器总是说:

Server error!

The server encountered an internal error and was unable to complete your request.

Error message:
End of script output before headers: te.py

If you think this is a server error, please contact the webmaster.
Error 500
localhost
Apache/2.4.16 (Unix) OpenSSL/1.0.1p PHP/5.6.12 mod_perl/2.0.8-dev Perl/v5.16.3 

代码是:

^{pr2}$

我自己失败了,也弄不清原因。请帮忙


Tags: pycomhttpbinserverubuntulinux教程

热门问题