简体   繁体   中英

Issue with using LocalStorage in PhoneGap for Android

To resolve : Application error - A network error occurred. (file:///android_asset/www/messagedetails.html?Id=29) in Android 4.0,I am using LocalStorage. This approach gave me the solution for the problem.But when the App is not run for long time or kept on hold., I am facing the issue again. I am not able to navigate from one page to another page. :(

I added the code to clear the App cache , is it the right approach???

Thanks in advance.

I do believe you are experiencing the "Unknown Chromium Error -6" issue. It's a known error in the Android 4.0 release that the file-URL can't contain parameters. (See further here: Android 4.0 Issue ). There are a number of possible solutions;

  1. Redesign to use LocalStorage for passing parameters around.
  2. Upgrading PhoneGap to 1.7+ (Cordova), seem to solve the issue. I haven't tried.

Hope it helps.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM