The standard way to load an URL into a WebView object is using the loadUrl method.

public void loadUrl (String url)

But if we need to load an URL into the WebView submitting POST data, use instead the postUrl method.

public void postUrl (String url, byte[] postData)

To create the POST data, use a string and encode it.

String postData = "submit=1&id=236";

    EncodingUtils.getBytes(postData, "BASE64"));
Share Button


Leave a Reply to vinay Cancel reply

Your email address will not be published.

Time limit is exhausted. Please reload the CAPTCHA.