Your problem is due to image caching which is done to improve browsing speed but causes problems when content changes. Images are cached by the browser locally and also potentially at one or more proxies between your browser and the website. You can supress caching using the Expires, Pramga: no-cache and Cache-control: no-cache directives in your http headers - but sadly this is not always respected by proxies and or browsers. For discussion see links at Re: http header / browser caching issues where you will find previous answers to this question with code and lots more discussion.
#!/usr/local/bin/perl
use CGI;
$query = new CGI;
print $query->header( -type => 'text/html',
-expires => '-1d',
-Pragma => 'no-cache',
-Cache-control => 'no-cache'
);
# this produces http headers which you could easily roll yourself
# if you don't wnat to use CGI.pm or CGI::Simple:
use POSIX;
my $expires = POSIX::strftime("%a, %d %b %Y %H:%M:%S GMT", gmtime(time
+()-24*3600) );
my $now = POSIX::strftime("%a, %d %b %Y %H:%M:%S GMT", gmtime(time
+()) );
print "Expires: $expires
Date: $now
Cache-Control: no-cache
Pragma: no-cache
Content-Type: text/html\n\n"
__DATA__
Expires: Fri, 07 Feb 2003 12:11:25 GMT
Date: Sat, 08 Feb 2003 12:11:25 GMT
Cache-Control: no-cache
Pragma: no-cache
Content-Type: text/html; charset=ISO-8859-1
When you add these headers you will find that when using the back button you get a page has expired message and the image is pulled down from the website every time.
tachyon
s&&rsenoyhcatreve&&&s&n.+t&"$'$`$\"$\&"&ee&&y&srve&&d&&print
|