Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I found out that when pressing back button it gets previous page from browser cache even if I send following headers:

Test1.aspx

Server              ASP.NET Development Server/9.0.0.0
Date         Wed, 24 Mar 2010 17:49:40 GMT
X-AspNet-Version 2.0.50727
Location         Test2.aspx
Cache-Control no-cache, no-store
Pragma         no-cache
Expires         -1
Content-Type text/html; charset=utf-8
Content-Length 189
Connection         Close
See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
515 views
Welcome To Ask or Share your Answers For Others

1 Answer

expires should be a date+timestamp and cache-control"s "must-revalidata" & "max-age" might help as well?

Expires: Wed, 11 Jan 1984 05:00:00 GMT
Cache-Control: no-cache, must-revalidate, max-age=0

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share

548k questions

547k answers

4 comments

86.3k users

...