Setting up a browser cache policy

  • Thread starter Thread starter helveticus
  • Start date Start date
H

helveticus

How can I assign expiration dates for external js scripts? For
instance, I would like to update the expiration date of
a js script by one hour after the last fetch. Does this make sense? I
have seen some examples suggesting changing header pragmas, etc., but
nothing really specific about asp.net. I am aware about page
OutputCache declarations, but how can this be applied to external js
or css scripts? All external scripts are declared inside the header.
(I am using Ajax). TIA for any pointers.
 
to set the cache headers for js files, they need to mapped to asp.net for
processing in iis (unless you are using ii 7.0). then with a httpmodule, your
code woudl check if the request is a js file, and set the cache header.

-- bruce (sqlwork.com)
 
Thanks for the reply. I kind of get the picture, but need to flesh out
the details. Do you know by chance some links to probe further?
 
Back
Top