I have a jsp page which takes a parameter from my Java code and calls the URL onLoad as below.
When I do this the form strips the resultant Url's parameters. As in everything after ? is stripped. So the below result url http://hostname/abc?data=123
appears as http://hostname/abc
which is not expected.
What am I missing or is it completely wrong to use form for GET
requests. Is there a better way to do this using javascript like window.location=result;
My jsp page is:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
</head>
<body onload="javascript:document.Form.submit()">
<%
String result = (String)request.getAttribute("result");
%>
<form action= <%= result %> method="get" name="Form">
</form>
</body>
</html>