If u use the servlet API to track sessions, the server will resort to URL
rewriting when client cookies are disabled. So, if use a session.putValue()
or session.getValue(), either cookies OR URL rewriting used @ the client
side. Note that you have to encode ALL URLs for URL rewriting to work. The
way you do it is:
response.encodeUrl(url_string) for POST and HTML A HREFs
response.encodeRedirectUrl(url_string) for all redirects...
To test if your web app works with URL rewriting, simply disable cookies and
check whether some sort of a session id is appended to all URLs.
Hope this helps,
Shrisha
----- Original Message -----
From: "Marc Krisjanous" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, April 16, 2000 7:04 PM
Subject: Session testing question
> Hi all,
> I have a shopping cart Servlet. The Servlet stores the shopping cart in
the
> session object and the JSP pages accesses the session shopping cart. Now
> that I have completed the code I was thinking about the situation where
the
> client could deny cookies. Now I have tested this on IE5 (disabling
cookie
> acceptance) and my Servlet does not work! It treats each session access as
> new. The question I have is:
>
> How can I check to see if cookies have been disabled and if so what can I
> use to still use the shopping cart?? I have heard of URL rewriting? Could
I
> use this instead of storing the shopping cart in the session object if
> cookies are disabled?
>
> Here is my infrastructure:
>
> 1.Websphere 2.x
> 2.JSP version 0.91
> 3.JDK 1.1.8
>
> Cheers
>
>
> Marc
>
>
===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
> http://java.sun.com/products/jsp/faq.html
> http://www.esperanto.org.nz/jsp/jspfaq.html
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets
__________________________________________________
Do You Yahoo!?
Talk to your friends online with Yahoo! Messenger.
http://im.yahoo.com
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets