Hi all.
In my web application (a book store), I have a
servlet that add a specific item to the shopping cart.
for session tracking, I have used the HttpSession object for the servlets and JSPs.
you know like:
session.setAttribute("cart", "some item");
and the link that invokes this servlet is :
----------------
<a href="/store/add?itemId=<%= rs.getString("isbn") %>">Add To Shopping Cart</a>
----------------
every thing work fine, but when disableing the cookies, a NullPointerException is thrown.
can I detect if the user is disabling the cookies ? and if disabling them
How to switch to url rewrite, and if switch, how to keep tracking the user ?
(I mean, every url will have a jsessionid and a long id, and if the user clicks View Shopping Cart, then how my
JSP can benefit from the jsessionid number, how to extract it ?)
please help me, coz this subject is very important to me...