0

I'm trying to create a static webpage that is cached in the browser. However when I take down the website the browser gives a 404 error. I'm using the manifest attribute in HTML like so.

<html manifest="manifest.appcache">
<head>
    <title>Connection Verification</title>
</head>
<body>
    <h3>Testing Connection...</h3>
</body>

my manifest.appcache looks like this.

CACHE MANIFEST
#Nothing to load here

I assume the top level HTML file is implied.

I am also sending the cache-control header in the response.

cache-control: public max-age:3153600

However when I bring down the webserver and reload the page it still gives a 404 error. Is there some way to force browser to cache?

Heretic Monkey
  • 11,687
  • 7
  • 53
  • 122
Tommie Jones
  • 957
  • 1
  • 16
  • 37
  • Does this answer your question? [HTML5 AppCache: how to implement offline mode if server isn't accessible but network is accessible](https://stackoverflow.com/questions/14506532/html5-appcache-how-to-implement-offline-mode-if-server-isnt-accessible-but-net) – Heretic Monkey Mar 08 '22 at 13:58
  • Note that appCache is [deprecated](https://developer.mozilla.org/en-US/docs/Web/API/Window/applicationCache) – Heretic Monkey Mar 08 '22 at 13:59

0 Answers0