httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Randy Terbush <>
Subject Re: mod_imap.c
Date Tue, 04 Jul 1995 16:49:57 GMT
>    Date: Mon, 3 Jul 1995 16:33:31 -0700 (PDT)
>    From: Brian Behlendorf <>
>    If you're saying that you have a bunch of directories with a bunch of 
>    common subdirectories that you want one map file to serve, then yes, I 
>    suppose you'd have to look at Referrer to get the context, since the 
>    Location: header returned has to be a full URI, not a relative one.  That 
>    seems rather specific - it could also be accomplished by having 
>    soft links to the imap file between directories.  *shrug*.

The sym-link solution is one I admitedly did not consider. I do think
that the solution I came up with is cleaner since it prevents me from
having to maintain a web of symlinks.  I may even see a way to fix the
problem that RST pointed out with a user storing an invalid URL due
to Location: munging.  I'll see if I can make that work. One note
about my solution is that I am *only* using the Referer: IF the URL
listed in the mapfile doesn't have 'http:' in it's URL. I suppose
that the proposal listed below could make this a bit safer.

The details of my application are that within the city information
pages I am developing (, I am making heavy
use of directories and Multiviews to accomplish some navigation and
search features.  Each directory has a "search_index" file that is
generated by GlimpseHTML.

I #include a bottom menu image that has a couple of relative URLs
to provide a path to the directory above, and to access the search
tool in that directory.  It could be a real mess to symlink or copy
the map file to every directory.

> How's about this for a compromise --- toss a new directive, base_uri,
> into the mapfile syntax, which specifies the interpretation of
> relative URIs which occur in subsequent map directives.  I figure on a
> subcommand set like:
>   base_uri map             # relative to the map itself
>   base_uri referer         # relative to the Referer: supplied by the browser
>   base_uri path_info       # relative to whatever came in as PATH_INFO
>                            # for the request (which gives the document that
>                            # included the map complete control over
>                            # how relative URIs are interpreted).
>   base_uri /literal/dir/   # Why not?  It could save someone typing ;-).
> My proposal is, then, to make "base_uri map" the default, but to have
> the other options available if anyone wants them.  The syntax is a
> straw man, of course.  Comments?
> rst

View raw message