Jack
Jack

Reputation: 15872

Only cache images with app cache

Is it possibly to only cache images in the html5 app cache?

My manifest which almost works!

CACHE MANIFEST
#Version: 4

CACHE:
Public/Images/about.png
Public/Images/android.png
Public/Images/back-hover.png
Public/Images/back.png
Public/Images/contact.png
Public/Images/HTML5.png
Public/Images/info.png
Public/Images/linkedin.png
Public/Images/mail.png
Public/Images/message.png
Public/Images/portfolio.png
Public/Images/profession.png
Public/Images/ram.png
Public/Images/stack.png
Public/Images/tile.png
Public/Images/vs.png
Public/Images/About/me.jpg

NETWORK:
*

FALLBACK:

The issue is that the landing page of my website is also getting cached, this means when I update the content the user isn't receiving the content.

I could force a manual update of all cached files by incrementing the version number in the cache, but it's not ideal as my main pages content is dynamic.

Upvotes: 1

Views: 370

Answers (1)

robertc
robertc

Reputation: 75777

Use an iframe to load a static HTML file which references the manifest.

Upvotes: 1

Related Questions