A request comes from the client for the first page,he enters some data in that page and submits the page,it carries him to the second page to enter some more info and after he submits this second page it carries him to the third page,in the third page we get little more info and save the data in datbase under his name. So we've to maintain the session from the first page through to the third page.
So here we get the session in the Second page.
Now my doubt is : If we disable cookies in the browser, In the second page form tag - action attribute- Do we need to put the third page as like below ?
In the above code Is that encodeURL necessary to maintain session for the third page since we disable cookies ?
posted 9 years ago
Yes, you need. Using encodeURL() your url will be appended a ';jsessionid=<your session id>'. This way, you can work with session without taking care of where your session id comes from. However, if you need to know it, you can use HttpServletRequest.isRequestedSessionIdFromCookie() method.
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads