Hi all,
I want to find out if cookies are enabled or not in a client's browser.for this what i am doing is, first in one of the
jsp pages i set up a cookie and then when the user clicks on the submit button he is forwarded to a servlet.this
servlet checks for existence of the cookie set by the jsp page.if the cookie is there then the browser supports cookies otherwise not.my problem comes in here.
in the servlet when i try getting a session using
"HttpSession session = req.getSession(true);"
i am able to find out if the browser supports cookies.but on the other hand if i use
HttpSession session = req.getSession(false);
i dont get any output from the servlet.my question is, since the jsp page has already set up a session, why doesn't the second method works?
any help would be greatly appreciated.
Subbu