I am new in Payment Gateway. Currently, I am working on a mobile app where I need to integrate PayU payment gateway in android app.
So far, I have created a code for TES
I think your code is okay, I am also doing same and got to know from payu that test merchant_key and salt is not working currently. Try for production mode.
If you want to load data from server use(postUrl):
post_Data = "hash="+PayMentGateWay.this.hash+"&key="+merchant_key+"&txnid="+PayMentGateWay.this.params.get("txnid")+"&amount="+PayMentGateWay.this.params.get("amount")+
"&productinfo="+PayMentGateWay.this.params.get("productinfo")+"&firstname="+PayMentGateWay.this.params.get("firstname")+
"&email="+PayMentGateWay.this.params.get("email")+"&phone="+PayMentGateWay.this.params.get("phone")+
"&surl="+PayMentGateWay.this.params.get("surl")+"&furl="+ PayMentGateWay.this.params.get("furl")+
"&service_provider="+ "payu_paisa";
webView.postUrl("https://secure.payu.in/_payment", EncodingUtils.getBytes(post_Data, "base64"));
I hope this help.