Client Code
function Call()
{
var value = $('input[name=form]:checked').val();
if (typeof(value)=='undefined')
{
alert('Select One Record');
return false;
}
else
{
$("#bean\\.id").val(value.split("@@")[0]);
var id = $("#bean\\.id").val();
$.post("search.do", {'id': id},
function(data){
});
}
}
<s:hidden name="bean.id" id="bean.id" />
<s:iterator var="form" value="#request.list" status="offset">
<input type="radio" name="form" value="${form.id}@@${form.status}"></input>
</s:iterator>
Server Code Struts2 config XML
<action name="search" class="<action name>" method="search">
<result name="success" type="json">
<param name="includeProperties">returnString</param>
</result>
</action>
Java Action Function
public String search() throws Exception
{
String id_server = context.getRequest().getParameter("id");
// Do some stuff
return SUCCESS;
}
Using Websphere 8.5.0.4.
It seems that sometimes the request parameter is not existed.
(id_server=null)
Does anyone have any idea why this happen?
I have other places using very similar code without problem.
I have failed to re-produce the problem. But my testing environment is Websphere 8.5.5.4.
I am not sure if this is the Websphere problem as the problem area is using 8.5.0.4 (Production environment).
Does anyone have any idea with this problem? Mainly I want to know the reason as I may need to explain.
Many Thanks