|
Jim Gallacher
jpg at jgassociates.ca
Fri Apr 28 13:13:03 EDT 2006
Alejandro Michelin Salomon ( Adinet ) wrote:
> Hi:
>
> I am new to python.
>
> I need same help.
>
> I add this line to httpd.conf --> LoadModule python_module
> modules/mod_python.so
>
> And then :
>
> Apache DocumentRoot is "D:/webroot"
>
> <Directory "D:/webroot/test">
>
> AddHandler mod_python .py
> PythonHandler mptest
> PythonDebug On
> </Directory>
>
> I runs --> localhost/test/mptest.py
>
> Runs ok a test
>
> When try tu run the same file in localhost/mptest.py
>
> The apache only prints python code in the page.
>
> Who to run others .py files out of localhost/test, or configuring modpython
> to work in all subdirectories under
> localhost structure?
You could use the publisher handler and configure your webroot directory
accordingly:
<Directory "D:/webroot">
AddHandler mod_python .py
PythonHandler mod_python.publisher
PythonDebug On
</Directory>
Check the documentation for more information on publisher.
Jim
|