How can I intercept a JSON response of a POST request in a WebView? How can I intercept a JSON response of a POST request in a WebView? json json

How can I intercept a JSON response of a POST request in a WebView?


Override shouldOverrideUrlLoading on the webclient :

@Overridepublic boolean shouldOverrideUrlLoading (WebView view, String url) {    URL aURL = new URL(url);             URLConnection conn = aURL.openConnection();             conn.connect();             InputStream is = conn.getInputStream();             // read inputstream to get the json..            ...            ...            return true;}