There's actually 2 cookie specs: the current one and an older netscape
specification. I don't think that IE abides by the netscape spec
(shocking!). You might have to detect the browser and act accordingly.

That's the greatest thing about standards, there's so many to choose from.

Craig

Craig Pfeifer
Software Engineer
Aether Systems, Software Products Division
703.847.3303 x2053
[EMAIL PROTECTED]

  


> -----Original Message-----
> From: John Towell [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, April 12, 2001 4:05 PM
> To: '[EMAIL PROTECTED]'
> Subject: RE: Weird Cookie Behavior 
> 
> 
> I am experiencing similar problems setting cookies.  However, 
> I have found
> that it is browser dependent, ie.,  works fine with Netscape (4.7) but
> doesn't set with IE 5.5 .. What browser are you using?
> 
> > -----Original Message-----
> > From: David M. Rosner [mailto:[EMAIL PROTECTED]]
> > Sent: Thursday, April 12, 2001 1:41 PM
> > To: [EMAIL PROTECTED]
> > Subject: Weird Cookie Behavior 
> > 
> > 
> > Hi All,
> > 
> > I have a jsp that sets a cookie named 'riCookie'. For some 
> > reason this 
> > cookie will not be sent to the browser unless I set an 
> > additional cookie 
> > after that. Here is the code:
> > 
> > This doesn't work:
> > 
> > <%
> >      response.addCookie( new Cookie("riCookie", "DATA" ) ) ;
> >      response.sendRedirect( "/someOtherPage.jsp" );
> > %>
> > 
> > But this does work:
> > <%
> >      response.addCookie( new Cookie("riCookie", "DATA" ) ) ;
> >      response.addCookie( new Cookie("Something", "More DATA" ) ) ;
> >      response.sendRedirect( "/someOtherPage.jsp" );
> > %>
> > 
> > Any idea why? I tried other names with the word 'Cookie' in 
> > them and they 
> > seem to work as well.
> > 
> > Thanks for any help,
> > 
> > -dave
> > 
> > 
> 

Reply via email to