Tech Off Thread

9 posts

Forum Read Only

This forum has been made read only by the site admins. No new threads or comments can be added.

ASP.NET 1.1 Cache

Back to Forum: Tech Off
  • User profile image

    I am working on a data application in ASP.NET 1.1.
    Part of the requirements are that each request for a page must deliver the page from the server. 
    What is the best way in your opinion/fact to prevent any client/proxy/server caching and force the server the redeliver the page for each request?

    Set IIS to expire the page immediately in the http headers?
    Progamatically do it in Page_Load for each page?
    Other ways?

  • User profile image
    Sven Groot

    Put this on your page:
    <%@ OutputCache Location="None" %>

    That'll cause ASP.NET to specify the appropriate cache headers to prevent client caching.

  • User profile image

    Thanks Sven.
    Is there a programmatic equivalent? 
    There are many pages in this project and it would be easier for me to stick it in the BasePage than the header of each individual page.

    I think I found it:


  • User profile image
    Sven Groot

    Yep, that works too.

  • User profile image

    Can u plz help me in the scenerio which is some what the same .. .as its addressing here


    we have a proxy server which is assigned by a fixed ip and user access it through proxy ...

    we have deployed our application over there, which is built in  ASP.NET 2.0 and we have also used seperate javascript files (*.js) and proxy server as usual caches the page and javascript files

    when ever we have some changes we deploy our application again at the proxy server 

    but when we run the application it uses the same cached javascript files and dont use the new one which we have deployed

    can you help me in this regard that what should i do ???

    wat should i do inorder to stop proxy server to cache javascript files

  • User profile image

    Which proxy server are you using?

  • User profile image

    We are using Squid 2.5 as our proxy server

  • User profile image

    We have done this in our Page.

      protected override void OnLoad(EventArgs e)







    But this solves the problem only on LAN.

    For fixed IP, caching problem persists.

  • User profile image

    plz if u can .. do help me in this problem of controlling caching at various level

Conversation locked

This conversation has been locked by the site admins. No new comments can be made.