I am using the JQuery $.ajax post command to invoke an ajax event on my web server:
var formParams = "fe1=y&fe2=m&fe3=m";
$.ajax({
type: 'POST',
url: '/foo.jsp',
async: false,
data: formParams,
complete: function(xmlRequestObject, successString){
ymmReceiveAjaxResponse(xmlRequestObject, successString);
}
});
The ajax component successfully calls the web page, but it does not include any of the post data.
ie - "(HttpServletRequest) request.getParameterMap.size() == 0"
- I'd expect 3, but am getting zero.
Changing the above command from POST to a GET makes everything work just fine.
TIA
The cause of the problem was found using FireBug and opening the opening the Net gadget.
I'm seeing that the web server is responding with a status 302 on the call to the web page.
Expanding upon the 302 request in Firebug/Net, and examining the Params, Headers, Response, and HTML quickly identified that it was an application specific issue originating on the server.
Thanks for everyone's feedback
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With