WoW Gold - Find jobs - Debt Consolidation - Reference 2007 - Sport Betting Systems

PDA

View Full Version : JS cache issue


tom007
Dec 3rd 2006, 7:56 pm
Hi ,

I am developing a section where we are going to host 1000's of videos. Now most of the site is going to be coded in ajax. So there are going to be several js files

My question is , is it good t cache those js files so save time and make your page load faster? Those files are going to be change once a month, so can be put something in the headers to download it again if it was modified since last access time

Yeldarb
Dec 6th 2006, 3:17 pm
Yes, there is a header for that. If I remember correctly it's

<?PHP
header("Pragma: no-cache");
header("Cache-Control: private, must-revalidate");
?>

tom007
Dec 6th 2006, 3:25 pm
This is the header currently sent by my application

post-check=0, must-revalidate, no-store, no-cache, pre-check=0

So basically, it is revalidating each time....

I have explained more about this issue in this thread

http://forums.digitalpoint.com/showthread.php?t=190680