0

i noticed that some complex html5 websites does not load properly on all devices. For example, Samsung Galaxy S5 does not load properly those complex html5 websites. Instead of it the webview shows a black empty website.

This haves any explanation?

this is my webview:

    webView.getSettings().setJavaScriptEnabled(true); 
    webView.getSettings().setSupportZoom( allowZooming );   
    webView.getSettings().setBuiltInZoomControls(allowZooming);     
    webView.getSettings().setLoadWithOverviewMode(true);
    webView.getSettings().setUseWideViewPort(true);
    webView.getSettings().setPluginsEnabled(true);
    webView.getSettings().setDomStorageEnabled(true);
    webView.loadUrl(url);

This is the game that does not work: http://tinyurl.com/krahudh

NullPointerException
  • 36,107
  • 79
  • 222
  • 382

1 Answers1

1

I am sorry this response comes so late. Hopefully you have been able to find a solution to this issue already, but in case you are still working on it: I had a very similar problem and this person's, Android webview does not load the page but app load from browser, answer helped in my situation anyways.

webView.getSettings().setDomStorageEnabled(true);

Although, I altered it slightly in the code I used to best suit the purposes for which I was using it. The code I used was

myWebView.getSettings().setDomStorageEnabled(true);

. I hope this helps.

Community
  • 1
  • 1
Chad
  • 41
  • 3