httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From (David Robinson)
Subject Re: Content-type negotiation: thoughts and code
Date Thu, 16 Mar 1995 22:25:00 GMT
rst wrote:
>   I would suggest this syntax for a content negiotation map file:
>   <!--#select
>      language="en"
>      type="image/gif; qs=1."
>      file="pic.gif"
>   -->
>   That way, it would be easier to integrate this feature into .shtml parsing.

>If you're suggesting that map files, i.e. files whose sole purpose is
>to direct the content-negotiation process, and not to be shipped to
>clients, should look like .shtml, I'm not sure I see why that's a good
>idea.  (It doesn't make things any easier to write, BTW; the includes
>code is committed to writing whatever it finds down a FILE*, which is
>very much the wrong thing when you're still trying to figure out what
>to retrieve.  Besides, for a variety of reasons, I'm trying to
>minimize the impact of my current content-negotiation work on the rest
>of the server).

It may not make it easier to write, but it's one less thing for the user
to understand. In fact, what I was getting at was this; suppose I want
to do a server-side include of a document subject to content-negotiation.

In the near future (when we have some working patches), you would have to
<!--#include--> another document that was a mapfile. What I was hoping for in
the long term was for the shtml file to be able to do content-negotiated
includes directly. So that map files would be a sub-set of general shtml

>  Note that it should also be possible for the selected object to be a directory,
>   although you'd have to cope with multiple map files in a single path.
>   (e.g. as in http://host/path/language-map/countries/image-map/canada)
>I'm not sure I understand what you're requesting here.  Is the
suggestion that "language-map" would map directories like
>  en
>  kr
>  fr
>and then "image-map" would direct MIME type discrimination?  If so,
>it's a neat idea, but *very* hairy to implement, in the context of the
>NCSA base code.  I'd prefer to get one-level discrimination working
>solidly first, before having a go at this.  That's messy enough!

Absolutely! (Yes, the server could return /root/fr/countries/gif/canada.gif)
I was only trying to suggest these 'next generation' features in case
they might affect how you'd implement the features you want right now.
There's nothing like looking ahead...


View raw message