[mod_python] Automaticaly requesting "index.py/index"

Dave Britton dave at davebritton.com
Mon Oct 24 18:56:21 EDT 2005


You also need to be sure that your index.py progrm contains an index
function (that is, def index(req): ... etc)
----- Original Message ----- 
From: "Graham Dumpleton" <grahamd at dscpl.com.au>
To: "Fabien Schwob" <skink at evhr.net>
Cc: <mod_python at modpython.org>
Sent: Monday, October 24, 2005 6:32 PM
Subject: Re: [mod_python] Automaticaly requesting "index.py/index"


> Fabien Schwob wrote ..
> > Hello,
> >
> > I'm currently trying to develop a website in python and I have a problem
> > to automatically request the "index.py/index" url.
> >
> > I have a script called index.py at the url http://jibaku.net/beta/ and
> > when I type the previous url, I only get a "404 Not Found". I must
> > request http://jibaku.net/beta/index.py/index to get the correct page.
> > So, is there a solution to tell mod_python to automatically get :
> >      http://jibaku.net/beta/index.py/index
> > when I type
> >      http://jibaku.net/beta/
> >
> > My configuration is an .htaccess in the beta/ folder and it contain :
> >
> > AddHandler python-program .py
> > PythonHandler mod_python.publisher
> >
> > Thanks in advance for your help.
>
> Try:
>
>   DirectoryIndex index.py
>
> Otherwise it will only work when you are using the SetHandler
> directive and not AddHandler. Using SetHandler will cause all
> requests against the directory to be intercepted and handled
> by mod_python.publisher, which may not be what you want.
>
> Graham
> _______________________________________________
> 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