[thelist] sigh...caching issue again!

Feingold Josh S Josh.S.Feingold at irs.gov
Tue Jul 2 07:10:00 CDT 2002


--
[ Picked text/plain from multipart/alternative ]
> how can i cache the images so they dont load
> everytime?

What happens if you leave out all of the headers?  I
thought that most browsers will cache images
automatically no matter the browser setting *as long as they have the same
name.*

Josh


-----Original Message-----
From: Erick Papadakis [mailto:erick_papadakis at yahoo.com]
Sent: Tuesday, July 02, 2002 2:38 AM
To: thelist
Subject: [thelist] sigh...caching issue again!


hello, i am sure this is a breeze of a question for
some of you, but really, i have searched a lot but
have found no solution that works for me.

what i need to is simple: to cache ('preload'?) my
images when a user comes to my website on first page.
same images are used all through my websie but it
seems that each page is loading the images again and
again!

i tried looking at cache pragma HTTP-EQUIV tags etc,
but most websites suggest not to do this and send php
http headers instead. so here is what i am doing:

    header("Expires: Mon, 26 Jul 2007 05:00:00 GMT");
  // Date in the future
    header("Cache-Control: store, cache");  //
HTTP/1.1
    header("Cache-Control: post-check=120,
pre-check=240", false);


i am not sure if this really works at all because the
images seem to be loaded everytime! in IE, opera as
well as in netscape! in my HTML, inside the javascript
source tags, i do this to preload:

    bg           = new Image();
    bg.src       = "bg.gif";
    spacer       = new Image();
    spacer.src   = "spacer.gif";

    ...and so on for every image....



help!
erick

__________________________________________________
Do You Yahoo!?
Sign up for SBC Yahoo! Dial - First Month Free
http://sbc.yahoo.com
--
For unsubscribe and other options, including
the Tip Harvester and archive of thelist go to:
http://lists.evolt.org Workers of the Web, evolt !



More information about the thelist mailing list