I am trying to figure out which correct settings allow appcache to be enabled in an Android web browser. I debated a lot about this, but none of them worked.
Given that AppCache is installed correctly (it works on chrome), my incorrect settings in web browsing are:
mWebView = (WebView) findViewById(R.id.activity_main_webview); WebSettings webSettings = mWebView.getSettings(); webSettings.setJavaScriptEnabled(true); webSettings.setDatabaseEnabled(true); webSettings.setDomStorageEnabled(true); webSettings.setAllowFileAccess(true); webSettings.setAppCachePath("/data/data/"+ getPackageName() +"/cache"); webSettings.setCacheMode(WebSettings.LOAD_DEFAULT); webSettings.setAppCacheEnabled(true); webSettings.setSupportMultipleWindows(true); mWebView.setVerticalScrollBarEnabled(false); mWebView.loadUrl("http://www.myapp.com");
Any idea why this is not working?
android webview html5-appcache
Billybelly
source share