At the time, you are submiting the form, you are creating a new request. So, your mainJSP.jsp cannot see the old request. If you have some input elements in the form, then they will be populated into the new request and you will have access to them in your mainJSP via request.getParameter("name_of_the_Parameter").
stefan [ March 15, 2005: Message edited by: Stefan W. ]
Joined: Aug 20, 2004
Thanks stefan. I understood the reason why it is not available to the next page. I have one more problem. Please have a look on it. I am setting a variable into request and forwarding it to some other page. Yes the variable will be available to me in request in next page. but I want to access this variable in a page which is inside a frame in the called jsp page. How can I do this? In this case also the page loading into frame will have a different request and will not have access to the parent page's request object. How can I access the request object of the parent page? Waiting for your reply.
Thanks and Regards
Joined: Mar 11, 2005
I think, if you work only with jsp, then you should use the <jsp:include> Tag.
It will include your subPage to the original and the request is provided.