hibrid0 Active Member Licensed User Longtime User Aug 6, 2019 #1 Hi I want to refresh a webview. The webview load html file from file.dirinternal, the user select a picture, the picture as the logo, I copied the picture to the file.dirinternal. I try to webview.invalidate and next webview.loadhtml, bit the images logo is the same. Try to remove the webview, re add with activity.addview and webview.loadhtml.,same result, the logo image is the same. Try to set cache mode off. If I close the app and reopen, the logo take the change.
Hi I want to refresh a webview. The webview load html file from file.dirinternal, the user select a picture, the picture as the logo, I copied the picture to the file.dirinternal. I try to webview.invalidate and next webview.loadhtml, bit the images logo is the same. Try to remove the webview, re add with activity.addview and webview.loadhtml.,same result, the logo image is the same. Try to set cache mode off. If I close the app and reopen, the logo take the change.
JohnC Expert Licensed User Longtime User Aug 6, 2019 #2 If you use WebViewSettings library, there are a couple of different cache modes: Code: wvs.setCacheMode(wv,"LOAD_DEFAULT") wvs.setCacheMode(wv,"LOAD_NORMAL") wvs.setCacheMode(wv,"LOAD_NO_CACHE") wvs.setCacheMode(wv,"LOAD_CACHE_ONLY") wvs.setCacheMode(wv,"LOAD_CACHE_ELSE_NETWORK") Did you try them all? Upvote 0
If you use WebViewSettings library, there are a couple of different cache modes: Code: wvs.setCacheMode(wv,"LOAD_DEFAULT") wvs.setCacheMode(wv,"LOAD_NORMAL") wvs.setCacheMode(wv,"LOAD_NO_CACHE") wvs.setCacheMode(wv,"LOAD_CACHE_ONLY") wvs.setCacheMode(wv,"LOAD_CACHE_ELSE_NETWORK") Did you try them all?
hibrid0 Active Member Licensed User Longtime User Aug 6, 2019 #3 JohnC said: If you use WebViewSettings library, there are a couple of different cache modes: Code: wvs.setCacheMode(wv,"LOAD_DEFAULT") wvs.setCacheMode(wv,"LOAD_NORMAL") wvs.setCacheMode(wv,"LOAD_NO_CACHE") wvs.setCacheMode(wv,"LOAD_CACHE_ONLY") wvs.setCacheMode(wv,"LOAD_CACHE_ELSE_NETWORK") Did you try them all? Click to expand... Thanks for your reply, I try with Load_no_cache Upvote 0
JohnC said: If you use WebViewSettings library, there are a couple of different cache modes: Code: wvs.setCacheMode(wv,"LOAD_DEFAULT") wvs.setCacheMode(wv,"LOAD_NORMAL") wvs.setCacheMode(wv,"LOAD_NO_CACHE") wvs.setCacheMode(wv,"LOAD_CACHE_ONLY") wvs.setCacheMode(wv,"LOAD_CACHE_ELSE_NETWORK") Did you try them all? Click to expand... Thanks for your reply, I try with Load_no_cache