Recently I discovered that I need to write a PERL script which automatically refreshes my page (so the cache is not used). I know how to do this in sh, bash:
echo Content-type: text/html
but the problem is that I am using NT and IIS and I cannot run such shell scripts. BAT files are also not allowed, so I cannot make the script using a BAT file, otherwise it would be easy.
In fact "refresh" is not the exact word as you see from the shell script. I need to force the browser and the server not to use any cache.
So here comes the question:
How looks the PERL script for NT which does the same job as the shell script? Something like the lines below maybe?
print "Content-type: text/html \n\n");
print @fileData; close (FH);
I know that in fact I am asking you to write me a script... but obviously I couldn't manage with this task by myself...
I have included in my page the pragma no-cache in the meta tag... but it seems that it doesn't work... I have set up my page to expire 10 years ago... or to expire tight away when it is loaded... but This doesn't work on my computer. Here is the line I am using, tell me if there are mistakes:
<META HTTP-EQUIV="Expires" CONTENT="0">
Many thanks for your help,
with best regards,
print "Content-Type: text/html\n";
print "Pragma: no-cache\n\n";
open(FILE, "$filename") | | print "Cant open file $!";