Sunday, 15 June 2014

servlets - how to read the body of the HttpServletRequest where the request header content type is application/x-www-form-urlencoded in java -



servlets - how to read the body of the HttpServletRequest where the request header content type is application/x-www-form-urlencoded in java -

my httpservletrequest contains next information..

headers: accept-encoding: gzip, deflate x-chargify-webhook-signature: b048ad28f573829f52f05208aa522a6f x-chargify-webhook-id: "8233897" content-type: application/x-www-form-urlencoded accept: "*/*; q=0.5, application/xml" content-length: "47" body: payload[chargify]=testing&id=8233897&event=test

now, how read body request , separate body key/value pairs?

in servlet service() method having httpservlerrequest object.

by using request object phone call request.getparameter(paramname), can value request object

refference

servlets

No comments:

Post a Comment