Reputation: 117
I know this question is rather strange ,so let me explain. I got an html5 application, an avatar that answers questions. However, while not busy, i want my avatar to display a waiting animation. Got my video, and it works just fine, but it is a 2 secs video that i want to access without asking the server every time i have to play it, its just too much traffic. What i want is to download it once, and then be able to play it every time i need. Is there anyway to cache it? Other solutions are wellcomed too ^^.
Thank you guys
Upvotes: 0
Views: 3826
Reputation: 26142
I am not sure if that works, but you can try using cache manifest. Here is info on how to use it: http://www.webreference.com/authoring/languages/html/HTML5-Application-Caching/
Briefly:
<!DOCTYPE HTML>
<html manifest="manifest.cache">
....
manifest.cache
#What to cache for reuse
CACHE MANIFEST
index.html
stylesheet.css
images/masthead.png
scripts/misc.js
#What to cache in case network goes down (if network is up it will still try to load it from net)
NETWORK:
search.php
login.php
/api
#What to show when resource is not cached and no way to load it
FALLBACK:
images/dynamic.php static_image.png
Upvotes: 1