Hello everyone!

I just installed Python 2.5 and i want to use Python to build websites.
I could load mod_python successfully with Apache but i fail to let 
the .py-files to be executed!

In /htdocs/python i got my test file:

[code=python.py]
from mod_python import apache

def index(req):
        req.content_type = "text/html"
        req.write("<html><head></head><body>")
        req.write("<h1>Python is running with mod_python...</h1>")
        return apache.OK
[/code]

And then i got the following code in my httpd.conf:

[code]
<Directory "S:/XAMPP/htdocs">
        AddHandler mod_python .py
        pythonHandler index
        pythonDebug On
</Directory>
[/code]

But when i type "http://localhost/python/python.py"; it won't execute!
My browser just shows me the source code. :-(

Please, can anyone tell me what i have to do?


Thanks in advance!


~ Mathias
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to