[mod_python] mod_python.publisher handler question...

Chris Watson chris at voodooland.net
Sat Jan 6 21:02:09 EST 2001

I have seen people ask the same question I am about to in the archives.
But I didn't see an answer archived as well.

It's my understand that for each script in your python dir you NEED to
give it a PythonHandler of the same name? If I have foo.py and bar.py
I need to Directory directives one with PythonHandler foo one with
PythonHandler bar. Right?

What I read was that to eliminate this I could simply set the
PythonHandler to mod_python.publisher. And ALL .py scripts in the python
directory would work. But they don't. I'm sure I have it set wrong or I am
misreading the documentation. I have the following configured in apache:

<Directory /usr/local/share/apache/htdocs/python>
          AddHandler python-program .py
          PythonHandler mod_python.publisher
          PythonDebug On

And In that directory are 3 copies of the hell world script from the
documentation. Each with a different name and none of them work with the
above. If I change the handler name to one of the 3 scripts that one
script will work. Have I misread the doco and am wrong in interperating
that mod_python.publisher will execute *any* .py script thats called in a
url in the directory? OR have I simple not configured apache properly?

Im not on the list so reply to me directly please.

Thanks for you time. Have a good weekend everyone!


More information about the Mod_python mailing list