WebView loadUrl works only once

后端 未结 14 1733
长情又很酷
长情又很酷 2020-12-14 01:49

EDIT: I worked on this project years ago and unfortunately I cannot verify if any of the answers is working in the given scenario.

I am having hard time with one Web

相关标签:
14条回答
  • 2020-12-14 02:46

    Try setting a WebChrome client. The webview needs support of WebChrome Clint to work properly in some cases.

    wv.setWebChromeClient(new WebChromeClient());
    
    0 讨论(0)
  • 2020-12-14 02:47

    In onCreate, instead of using wv.loadUrl(Constants.BLOG_URL); , just use wv.loadDataWithBaseURL(baseUrl, readFileAsString("index.html") , mimeType, "UTF-8", null);

    0 讨论(0)
提交回复
热议问题