Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Enable content expiration

Status
Not open for further replies.

Patbeau

Programmer
Apr 7, 2003
32
0
0
CA
Hi,

Im not really good with IIS. I seen the option "Enable content expiration" (it is unchecked on all my sites now). My question is : If I check this case and check "Expire Immediately", will it overwrites the browser cache option? And what happen when it is unchecked ? What is the default option when it is unchecked.

Should I use "Expire Immediately" for all dynamic site with CMS ?

sorry for my english,

thank you,
patrice
 
Expire Immediately" forces Browsers (ie. Internet Explorer) to refresh page result even if they have Caching option enabled. In other words, user will have to contact your server to get new result, which can be very taxing on your server performance.

This is useful if you site contents changes very frequently, ei. you are showing holiday prices or a news website and do not want your users to see outdated information.

On the other hand if your site contents does not change for weeks on end disabling this option would speed up browsing experience for your users and will free up resources on your server as all of previously accessed pages would be stored on users' local machines.
 
Hi, something else you should know is that you can override this option by setting a "cache control" header on you web pages so you can control the expiration more precisely.

I don't recommend to use "expire immediately" value because I've seen lot of problems with this. For example, I've seen .PDF download over SSL failed because of this option configured on IIS server to mention only one.

If you really need to set the content expiration value, configure 1 minute but not "immediately".



Hope this helps. Please let me know if this resolve your issue

Jeff
 
In ASP Header line would be:
Response.Expires = 0

time is counted in minutes where 0 = expire immediatly.
(I think this is a universal value).

This way of controling cache gives you more flexibility as you can make exceptions for various pages. But remember, IIS overides Server-Side code options and caching has to be enables for this to work.
 
Thank you for your answer!

I will do the Response.Expires instead of IIS "Enable content expiration"...

 
Hi, actually, the IIS value is overriden by the cache control in your web page not the contrary.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top