in reply to image in <img> tag is not refreshed

Like in the previous contributions I'm asuming that you're not changing the image filename so when the browser reloads it takes the image from its cache ignoring the changes.

Now, to prevent the browser to cache your images just tell him to do it. Put the following Meta-Tag into your HEAD section of your HTML code.

<head> <META HTTP-EQUIV="CACHE-CONTROL" CONTENT="NO-CACHE" /> </head>

-- slayven
        trust in bash
        but tie your camel

Replies are listed 'Best First'.
Re^2: image in <img> tag is not refreshed
by Anonymous Monk on Nov 13, 2005 at 15:53 UTC
    that is html, and only affects the html file, not the image
      Hi,

      I just recently had a similar problem. To solve it, I added a .htaccess file to the directory with the images with the following content:

      ### activate mod_expires ExpiresActive On ### Expire .gif's immediately (0) after they have been accessed (A) ExpiresByType image/gif A0 ### or set "ExpiresDefault" for all files in the directory
      more on that here: http://www.apacheref.com/ref/mod_expires.html
      see ye,
      svenXY (currently not logged in)