I am trying to run an ajax call with jqGrid. However, the parameters are not being sent to the getRequest() all of the time.
If I do the javascript:
var param1 = document.getElementById("idInput").value;
var url = "${ctx}/Method.action?getTheseRecords¶m1="+param1;
Then when I call in the Java it comes back blank. However, I if set the var param1, then I get the right data.
So this works:
var param1 = "M";
var url = "${ctx}/Method.action?getTheseRecords¶m1="+param1;
So the first way gives an empty String, and the second gives a String == "M":
String param1 = getRequest().getParameter("param1");
I don't know if somebody knows why this isn't working? Because I have looked at the url before putting it into the Ajax, and it is fine.