[Zope] Image caching (was: Simple (I hope) question re: image s)

Jeffrey Robinson Jeffrey.Robinson@MCICoach.com
Tue, 29 Jan 2002 11:31:10 -0600


> -----Original Message-----
> From: Lennart Regebro [mailto:lennart@regebro.nu]
> Sent: Tuesday, January 29, 2002 11:20 AM
> To: Jeffrey Robinson; zope@zope.org
> Subject: Re: [Zope] Image caching (was: Simple (I hope) question re:
> images)
> 
> 
> From: "Jeffrey Robinson" <Jeffrey.Robinson@MCICoach.com>
> > In most of my documents I always have a <href base> within 
> the <head>,
> such
> > as:
> > <base href="http://manage.anecho.mb.ca/">
> >
> > In all events that I've seen the base href is prepended to 
> any referenced
> > link in the HTML document unless that link is preceded by 
> http:// (I might
> > be off on the mechanics, this is just an observation).
> 
> No thats quite true.
> 
> > Thus, if I have a link in my code, located anywhere on my 
> server with a
> base
> > href like shown above and the tag reads <img 
> src="images/picture.jpg">,
> the
> > browser pulls up 
http://manage.anecho.mb.ca/images/picture.jpg instead of
> looking for it relative to where the document came from.
>
> I wasn't certain that if having a base href then gives the browser a
> "canonical" address which it can use for caching; unlike the relative path
> problem that you mentioned.

Well, it does, but the base ref can be used for other uses too, inside zope.
I'm quite sure that it would be just as simpl to set the link to the image
with an absolute path instead, and actually having the base reference
pointing to the document. At least this has no secondary effects.

That's quite true, of course smacking everything with a base href like I
mentioned also can take away from some of the very reasons that folks use
Zope, too.  I think I also suffer from "old habits die hard" syndrome, from
working on static pages so long.

Thanks for the clarification, though.

Jeff