Quickest way to make py script Web accessible

rtilley at vt.edu rtilley at vt.edu
Thu Jan 5 11:48:44 EST 2006


This works well! Thanks for the advice. The docs for it should include
something about adding content_type = 'text\plain' otherwise, the
'testing' section of the tutorial is broken

It should look like this:
from mod_python import apache
def handler(req):
    req.content_type = 'text/plain'
    req.write("Hello World!")
    return apache.OK

Not this:
from mod_python import apache
def handler(req):
    req.write("Hello World!")
    return apache.OK




More information about the Python-list mailing list