Unable to see cached data after disconnecting from networkRSS

3 replies

Last post Sep 08, 2020 02:56 AM by Jalpa Panchal

  • Unable to see cached data after disconnecting from network

    Sep 02, 2020 05:33 AM|SghamIIS7|LINK

    Hi,

    I am learning how to provide offline access and I'm using local server IIS7.

    I wrote a very simple HTML5 web application,  saved it into IIS7 local server and it works fine as it should while connected to network.

    However after disconnecting from the network to go offline , emptying the browser cache,  I

    reloaded the application, yet i didn't see cached data.  It is as if IIS7 never got disconnected from network.  All the applications that I saved in Local host server behave  as if I am still online.

    Am I missing a step to  disconnect from IIS7  before disconnecting from network to see the application cache data?

    I do see the cache information if I type about: cache in address bar field.  But all applications yet work as if I am online.

    Thx.

       Shervin

  • Re: Unable to see cached data after disconnecting from network

    Sep 03, 2020 02:23 AM|Jalpa Panchal|LINK

    Hi,

    To enable cache in iis you could use the HTTP Response Headers feature.

    1)Open IIS Manager, select your site.

    2)double click the HTTP Response Headers  from the middle pane

    3)In the HTTP Response Headers pane, click Set Common Headers... in the Actions pane.

    4)In the Set Common HTTP Response Headers dialog box, check the box to expire Web content, select the option to expire after a specific interval or at a specific time, and then click OK.

    You could also refer below article for more detail information:

    https://docs.microsoft.com/en-us/iis/configuration/system.webserver/staticcontent/clientcache

    Regards,

    Jalpa

    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue.
    If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.
  • Re: Unable to see cached data after disconnecting from network

    Sep 04, 2020 02:56 AM|SghamIIS7|LINK

    Hi

    The attachment above is what i get after running the application on IIS 7.

    However after disconnecting the network, emptying the browser local  cache and reloading the

    application in IIS i should be getting the attachment below showing cached rate in red box.

    But it does not.  it shows the green box-loading the application offline.

    I did what you suggested with HTTP respond headers yet it did not work.

    I don't think IIS is disconnected when I disconnect the network.  That is

    why it still works as normal offline.

    Any more ideas maybe.

    Thx.

                Shervin

  • Re: Unable to see cached data after disconnecting from network

    Sep 08, 2020 02:56 AM|Jalpa Panchal|LINK

    could you share some sample code to reproduce the issue?

    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue.
    If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.