-
28 Dec 2012 2:19 AM #1
Unanswered: Application updates not working on Android
Unanswered: Application updates not working on Android
hi,
I have a small WebApp I created using Sencha Touch 2.0.1.
I'm using a Manifest file to update the users device.
While the updates are working perfectly on my iPhone the Android device will not update.
I load my new App to the server and the iPhone displays the "New version available ..." message and update the application but the Android device displays the old version and does not display the message.
I tried to:
* Delete and reopen it on the browser.
* Delete the phone's Cash and reload it.
* Delete the App from the home screen and reinstall
....
nothing seams to makesAndroid update the App
Anyone has an idea why that mite happen ?
I'm using Sencha Touch 2.0.1
I'm building it by "sencha app build production"
And my manifest is a PHP file :
ThanksCode:<?php header('Content-Type: text/cache-manifest'); echo "CACHE MANIFEST\n"; $hashes = ""; $dir = new RecursiveDirectoryIterator("."); foreach(new RecursiveIteratorIterator($dir) as $file) { if ($file->IsFile() && $file != "./manifest.php" && substr($file->getFilename(), 0, 1) != "."){ echo $file . "\n"; $hashes .= md5_file($file); } } echo "# Hash: " . md5($hashes) . "\n"; echo "\n"; echo "FALLBACK:\n"; echo "\n"; echo "NETWORK:\n"; echo "*"; ?>
Erez
-
30 Dec 2012 8:56 AM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,641
- Vote Rating
- 434
- Answers
- 3107
The new update available message is for the microloader loading delta updates. The cache manifest is something different. When the app is refreshed from the new update available message means that the delta update was downloaded and applied to localstorage. The cache manifest tells the browser to cache the files. The cache manifest would require a browser refresh because the files are downloaded the first time, then the browser can tell which files are new, the new files are then downloaded again to be cached.
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
2 Jan 2013 4:17 AM #3
Hi,
So if I understand correctly to get the APP updated I should should:
1) Load the new files in to the server
2) Update the manifest (which in my case happens by itself)
3) Open the APP on my mobile
The APP then :
1) Detects using the manifest that new versions of the files are available
2) Display a message "New updates ..." message
3) Load the new version of the files into the local storage
4) Reload the APP using the new version of the files.
The above process does work on my iPhone but on the Android device it does not.
On the Android I need to manually clear the device History, Cash and cookies to that the APP to load the new version of the files.
Am I doing something wrong ?
Erez


Reply With Quote