[mod_python] AddHandler on .htaccess

Graham Dumpleton graham.dumpleton at gmail.com
Wed Oct 3 06:50:16 EDT 2007


Are you sure your .htaccess file is actually being read and used and
you aren't just inheriting a fixed configuration from main Apache
configuration files?

If you insert junk in the .htaccess file, ie., invalid name which is
not a valid directive, such as string 'XXX', do you then get a 500
error and message in the Apache error log file. If you do, this would
indicate the file is being read, otherwise it isn't.

For other general commentary on SetHandler/AddHandler and mod_python see:

  http://www.dscpl.com.au/wiki/ModPython/Articles/SetHandlerVersusAddHandler

Graham

On 03/10/2007, Marcello Semboli <dinogen at yahoo.com> wrote:
> Hello, everybody.
>
> I'm writing a web application in python using mod_python.publisher and a template PSP system.
> I have Apache 2.0.55, mod_python 3.2.8 and python 2.4.4c1.
>
> If my .htaccess is:
>     AddHandler mod_python .py
>     PythonHandler mod_python.publisher
>
> everything works well. The page
> http://localhost/login.py
> and
> http://localhost/login.py/index render the correct page.
>
> But if I want to use a different extension, say, login.psp I can't get it works at all!
>
> I try to change login.py in login.psp and .htaccess as follow:
>     AddHandler mod_python .psp
>
>     PythonHandler mod_python.publisher
>
>
> and also:
>     AddHandler mod_python .psp
>
>
>     PythonHandler mod_python.publisher |  .psp
>
>
>
> In any case I got 404 Not Found.
> Restarting apache, flushing cache, removing various .pyc cannot fix the problem.
>
> Where is my error???
>
>
> ________________________________
> Marcello Semboli
> http://dinogen.hacknight.org
>
>
>
>
>       ___________________________________
> L'email della prossima generazione? Puoi averla con la nuova Yahoo! Mail: http://it.docs.yahoo.com/nowyoucan.html
>
> _______________________________________________
> Mod_python mailing list
> Mod_python at modpython.org
> http://mailman.modpython.org/mailman/listinfo/mod_python
>


More information about the Mod_python mailing list