httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r...@imdb.com (Rob Hartill)
Subject Re: function prototypes
Date Thu, 02 Jan 1997 00:47:35 GMT

So, on the subject of mod_perl and breaking rules how many points do I
lose (assuming I have any to lose) with this..

I wrote a mod_perl handler that implements a cut-down multiviews/language
negotiation module which Apache usually takes care of from mod_negotiation.c.
I intercept files that aren't found and then do a directory read to find files
that can be created from the base filename + 1 or more acceptable extensions.
(it won't map index to index.bak or index.core unless you explicitly say
"bak" and "core" are acceptable).

As well as adding ".html" to urls/filenames I also add .en, de, .fr, .it) if
I have them to offer and I use "Accept-Langauge" to pick the *best* based
on user preference.  ..now here's where I wander away from mod_negotiation.c,
if the luser has an "Accept-Langauge" of "fr" and I only have "en" and "de"
then I give them "en" instead of a face full of "406" response.

MSIE + mod_negotiation.c are a pain in the ass on this issue and I've
got too many rabid MSIE users moaning about the 406 responses. My reading
of an April draft of 1.1 suggest I can do this, but mod_negotiation prefers
to offer a menu of choices rather than pick a default.

Also, is a module allowed to change r->filename, refresh r->finfo then
return DECLINED so that other modules can play with the request. Or have
I broken another rule ? :-)


rob

Mime
View raw message