Why isn't a JS file hosted on Amazon S3 getting cached by the browser?
Posted
by Paras Chopra
on Stack Overflow
See other posts from Stack Overflow
or by Paras Chopra
Published on 2010-05-05T12:14:52Z
Indexed on
2010/05/05
12:18 UTC
Read the original article
Hit count: 130
I have a JS file hosted on Amazon S3 (http://s3.amazonaws.com/wingify/vis_opt.js). I want the file to be cached on users' browsers so that they don't have to download it with every page view. However, in spite of setting Cache Control header I don't think it is getting cached. Browser still contacts Amazon Server with every pageview.
Here is the example of page where this script is embedded: http://myjugaad.in/
If you have Firebug, you will be able to see that browser requests it with every pageview.
What can I do so that the file gets permanently cached? Thanks for help.
© Stack Overflow or respective owner