1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

How to blank IE cache via ASP?

Discussion in 'C#' started by JJnacy, Jun 15, 2009.

  1. #1
    I like to clean IE cache so IE do not keep old info.
    Please use ASP


    Thanks,
     
    JJnacy, Jun 15, 2009 IP
  2. dopanel.com

    dopanel.com Peon

    Messages:
    93
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Response.Buffer = -1 'All the buffer expires @ -1 second(1 second ago).

    But if you want to clean all the websites' tmp file of the browser ,then no command can do that!
     
    dopanel.com, Jun 15, 2009 IP
  3. DoDo Me

    DoDo Me Peon

    Messages:
    2,257
    Likes Received:
    27
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Response.Expires = -10000;
    Response.AddHeader('Pragma', 'no-cache');
    Response.AddHeader('Cache-Control', 'no-cache, must-revalidate');
    Response.CacheControl = 'private';
     
    DoDo Me, Jun 16, 2009 IP
  4. Corwin

    Corwin Well-Known Member

    Messages:
    2,438
    Likes Received:
    107
    Best Answers:
    0
    Trophy Points:
    195
    #4
    This is the only instruction that guarantees that the page will only be cached as long as needed:

    <%
    Response.AddHeader "cache-control","no-store"
    %>


    This means that the page will be removed from the user's cache immediately, when the user navigates away from the page.

    Be warned, however - if the user moves away from the page, and then hits the back button to go back to the page, because it has been removed from the cache it may cause problems depending upon your browser.

    According to RFC2616, "If sent in a request, a cache MUST NOT store any part of either this request or any response to it. If sent in a response, a cache MUST NOT store any part of either this response or the request that elicited it."

    Let me know if this helps!
     
    Corwin, Jun 17, 2009 IP
    JJnacy likes this.