[howto] install

xiaoxiao2021-03-06  143

Install MOD_PYTHON under Win2k

Environment: apache_2.0.50-win32-x86-no_ssl.msipython 2.3mod_python-3.1.3.win32-py2.3.exe

After installation, no mod_python.so copies c: /python23/lib/site-packages/mod_python_so.pyd is c: /apache/apache2/modules/mod_python.so

Open httpd.conf Add to LoadModule Python_Module Modules / Mod_python.so Settings The allowoverride of the test directory is at least FileInfo.

ALOWOVERRIDE All Options None ORDER ALLOW, DENY Allow from All

Add AddHandler MOD_PYTHON .PY PythonHandler First Pythondebug on

Where first, first means the test file is c: /apache/apache2/cgi-bin/first.py#! Python # filename: first.pyfrom mod_python import apache

Def Handler (Req): Req.content_Type = "Text / Plain" REQ.WRITE ("Hello World" Return Apache.ok

Start Apache, open the browser to enter http: // localhost: 8080 / cgi-bin / first.py

转载请注明原文地址:https://www.9cbs.com/read-128006.html

New Post(0)