[mod_python] Re: mod_python problem under WinXP

Graham Dumpleton grahamd at dscpl.com.au
Sun Aug 28 18:41:12 EDT 2005

> I am sorry for not removin set handler directive from config file. I
> placed it there accidentally. The normal lines are
> <Directory "D/www/python">
>    AddHandler python-program .py
>    PythonHandler mptest
>    PythonDebug on
> </Directory>
> And i did restart apache after making changes.

But was there a mod_python startup message in the Apache log file to
indicate that mod_python was in fact loaded?

I mentioned this last time and the document I linked to also talks
about it, but you didn't address my comment about it.

> As for win32 machines - i was forced to install the software and work
> on them. That was not my choice.
> As for directory path - it is all right. I inserted it from my
> DocumentRoot path and checked it.

If you are confident that that directory name will work, then use this:

   <Directory "D/www/python">
      deny from all
      AddHandler python-program .py
      PythonHandler mptest
      PythonDebug on

If it is correct, any attempt to access a page in that directory should 
back a "Forbidden" error response. If you don't get this, then something
isn't right with the directory name or the position of the directive in
the Apache config file.

You might also do what the linked document suggests, which is not to use
the main Apache configuration file, but use a .htaccess file in the
directory to want the scripts to be in. Use of a .htaccess file is less
prone to problems with getting the path correct as you don't need to
specify it.


More information about the Mod_python mailing list