您的位置:首页 > 编程语言 > Python开发

python for cgi

2009-09-09 17:20 204 查看
First when using "print" to output information to browser, the first line must be "Content-type: text/html". the value of type could be other file formats that browser can parse.

The second thins should be noted is that: the first line of python should be “#! python_path/python.exe -u" to print out to web-server.

or

Add "ScriptInterpreterSource Registry" to the bottom of Apache/conf/httpd.conf

and maybe you should to add:

SetEnv PYTHONUNBUFFERED 1

PassEnv PYTHONPATH
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: