I wrote:
I tried renaming WebKit/OneShot.cgi to index.cgi to use it as the
default DirectoryIndex. If I access it as
http://www.justrestingsw.com/index.cgi
everything works as expected. If I access it as
http://www.justrestingsw.com/
I get an infinite loop of 301 redirects.
I found the source of the infinite loop. It's happening in
Application.handleDeficientDirectoryURL. If I change the code at the start
to
if transaction.request().uri() == "/":
newURL = "/index.cgi/"
else:
uri = string.split(transaction.request().uri(), '?')
uriEnd = string.split(uri[0], '/')[-1]
# @@ gat 2000-05-19: this was changed to use a relative redirect
starting with "." to force
# a client redirect instead of a server redirect. This fixes problems
on IIS.
uri[0] = './' + uriEnd + '/'
newURL = string.join(uri, '?')
the infinite loop disappears, but this requires the assumption that
index.cgi is the DirectoryIndex handler. Is there some way to do this in a
less fragile manner?
--
Skip Montanaro ([EMAIL PROTECTED] - http://www.mojam.com/)
_______________________________________________
Webware-discuss mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/webware-discuss