Hello to everyone. The problem is as follows. I have a form that needs to be submitted which has the following form:
The jsp CompleteRequest.jsp does some processing to the parameters(formatting) and logs a cookie. Then depending on the value userType received, I wish to redirect to another page. I know that using a servlet for processing would be the ideal choice, but we were asked to use a jsp as an intermediate for the small amount of formatting. In the CompleteRequest.jsp I had written the following:
This however does not seem to work. I did a little checking and figured out that I cannot use absolute paths. Also I was just wondering if it is possible to not leave any trace of html code in case the process gets held up in the intermediate page for some reason.
I was just wondering if anyone could point me in the right direction. Any help or advice would be greatly appreciated.
I would rather do a send redirect from a servlet, like Bear suggested. That JSP is just sitting there with some controller logic and it was supposed to be the view. What is worse is that the user will never see any useful content on this page. He will simply be redirected to some other page, which means your view has completely been transformed to a controller. Use a servlet instead
Thank you both for your prompt response. I am glad my instincts were right. I a still a student and I don not pretend to know all. However some of our teaching assistants in my humble opinion, have learned a language but not how to actually use the tools they have learned. While other T.A s are great some leave a lot to be desired, as is this particular case. Again thank you for your time and help.