【发布时间】:2018-09-17 00:43:15
【问题描述】:
我想用POST 数据打开一个webview。所以我这样做:
webView = (WebView) findViewById(R.id.dashboard);
String url = "http://www.example.test";
String postData = "json=" + JSON;
webView.postUrl(url, postData.getBytes());
所以现在当我启动这个webview时,点击链接会打开设备的默认浏览器,有没有办法坚持webview打开链接?
我进行了研究,但所有这些都是针对GET 请求的。
【问题讨论】:
-
I researched but all of them are for GET requests.没关系,都一样
标签: android android-studio webview android-webview