Stopping pages from caching

Results 1 to 6 of 6

Thread: Stopping pages from caching

  1. #1
    Ky Guest

    Default Stopping pages from caching

    I have an ASP application in which I do not want the user to use the standard BACK/FORWARD buttons. However I don&#039;t want to remove them completely but instead I do not want to keep any pages cached, so that if they cick BACK they always get that &#039;this page has expired&#039; or something and have to hit refresh. This is because they will be deleting data from a database and if they go BACK the results shown will be incorrect as deleted data will be displayed again.<BR><BR>Is this possible?

  2. #2
    Ghose Guest

    Default RE: Stopping pages from caching

    U can try this(paste this code at the top of the page): <BR><BR>response.expires = 0<BR><BR>

  3. #3
    Ky Guest

    Default that didn't work

    thanks but that didn&#039;t work........the page was still there with the deleted data shown on screen =(<BR><BR>any other ideas?

  4. #4
    Ghose Guest

    Default RE: that didn't work

    see if this works...<BR><BR>response.expires = 0<BR>response.expiresabsolute = Now() - 1<BR>response.addHeader "pragma","no-cache"<BR>response.addHeader "cache-control","private"<BR>Response.CacheControl = "no-cache"

  5. #5
    Ky Guest

    Default That worked!

    thanks a million!<BR><BR>

  6. #6
    Join Date
    Dec 1969

    Default RE: that didn't work

    Try using the same line but with a different time<BR><BR>Response.Expires = -1500<BR><BR>At the top of the page.<BR><BR>Jarvis

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts