Skip to content Skip to sidebar Skip to footer

Zoom In/out In Webview Android

Hi i have used following code for built in zoom in zoom out control mWebView = (WebView) findViewById(R.id.webView1); mWebView.getSettings().setBuiltInZoomControls(true);

Solution 1:

Do you have a viewport meta tag in web page to display? If yes and if it contains user-scalable="no" then it is normal, the HTML itself disables zoom. Simply edit the tag like this:

<meta name="viewport" content="initial-scale=1.0, user-scalable=yes, width=device-width" />

Solution 2:

Try this, I got answer

WebSettings webSetting = mWebView.getSettings();
            webSetting.setBuiltInZoomControls(true);

Solution 3:

May be this is what your are searching..

settings.setBuiltInZoomControls(true);
settings.setSupportZoom(true);
settings.setUseWideViewPort(true);
settings.setJavaScriptEnabled(true);
settings.setJavaScriptCanOpenWindowsAutomatically(true);

Solution 4:

try this:-

webview.getSettings().setUseWideViewPort(true);

Post a Comment for "Zoom In/out In Webview Android"