Videos not showing in webview (Android)
I am implementing a web application for Android. In this application, I open a HTML page on webview. This HTML page contains videos, images and text. When I call this page, all stuff are showing except for videos. What can I do? Please help me.
I am using this code for this problem:
WebView web = (WebView) findViewById(R.id.webview);
web. getSettings().setJavaScriptEnabled (true);
web. getSettings().setJavaScriptCanOpenWindowsAutomatically (false);
web. getSettings().setPlu开发者_如何学GoginsEnabled (true);
web. getSettings().setSupportMultipleWindows (false);
web. getSettings().setSupportZoom (false);
web. setVerticalScrollBarEnabled (false);
web. setHorizontalScrollBarEnabled (false);
web. loadUrl ("http://www.abc.com/xyz.html");
web.setWebChromeClient(new WebChromeClient());
get a WebViewClient to check what url is on a hyperlink, if it is a video, you can redirect it to an embedded player.
精彩评论