Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android webview Load url doesn't work for Instagram webpage

I realized that not working for under android 4.3 versions.

I have an android app which has webview. When i try to load url "http://instagram.com" it's not working It shows blank page but facebook webpage is working. It's really important for me please help.

WebView view = (WebView) findViewById(R.id.webView1);
    view.getSettings().setJavaScriptEnabled(true);  
    view.loadUrl("http://www.instagram.com");
like image 962
mtuygun Avatar asked Dec 15 '15 21:12

mtuygun


People also ask

Does Instagram use WebView?

The key aspect here is that Instagram's app is using a Safari Webview but somehow it is injecting its own tracking pixel on the HTML body wether the target website had it or not.

What is Instagram WebView?

The Instagram web viewer is a private viewer, also known as an Instagram stalker, that allows you to check out public Instagram profiles without logging in. You don't need to create a fake or temporary Instagram account. You don't need to download the Instagram app on your phone.

What is a WebView URL?

WebView is a view that displays web pages inside the application. It is used to turn the application into a web application.


1 Answers

Have you tried using the method:

setDomStorageEnabled();

Sets whether the DOM storage API is enabled. The default value is false.

for example:

WebView view = (WebView) findViewById(R.id.webView1);
view.getSettings().setJavaScriptEnabled(true);  
view.getSettings().setDomStorageEnabled(true);
view.loadUrl("http://www.instagram.com");

I had previously problems loading Facebook and Twitter pages in some devices, solved using setDomStorageEnabled() method.

like image 151
Jorgesys Avatar answered Sep 18 '22 19:09

Jorgesys