Why is Android WebView refusing user input?

前端 未结 16 1869
半阙折子戏
半阙折子戏 2020-11-28 08:12

I\'m developing an Android application that uses a WebView to display the login page for Facebook. The page loads beautifully, and I\'m able to select the username/password

16条回答
  •  死守一世寂寞
    2020-11-28 08:52

    Not sure if it's the problem since other websites also display the same behavior, but have you enabled javascript? A WebView does not enable it by default.

    WebView webView = (WebView)findViewById(R.id.yourWebView);
    webView.getSettings().setJavaScriptEnabled(true);
    

提交回复
热议问题