Alex Rivera | Logout

HTML5 Offline app on Android devices

Asked 2013-01-30T19:50:23.850
18

This is regarding HTML5 offline apps on Android devices.

We are running into an issue where bookmarking an offline capable HTML5 app (with a complete cache manifest file) fails to load on the Android browser under the following conditions:

  1. Bookmark the app on the browser
  2. Switch off all wireless connectivity
  3. Close the browser completely
  4. Attempt to launch the bookmark from the homescreen

We end up with an "Unable to connect to the internet" message. The app works perfectly fine on iOS devices when saved to homescreen and on airplane mode.

Is there a specific way the app should be saved, or is this an Android specific quirk?

Edit
Report

1 Answer

1

What I encountered was that the .manifest files in Apache's mime.types configuration was correctly set to text/cache-manifest and then several lines below was overwritten as application/x-ms-application (for compatibility with MS' ClickOnce thing). To resolve this I've taken different file name ending, namely .cachemanifest, configured correctly its mime type, restarted Apache, renamed manifest file as cache.cachemanifest, changed my <html> manifest attribute to point to this file, and then I was finally able to cache my web app on Android (there wasn't any problem in desktop browsers which apparently don't care about the mime type of cache manifest file). Hope this helps.

answered 2013-06-12T12:57:01.773

Your Answer