wood burning stoves 2.0*
The moose likes Servlets and the fly likes servlet not finding the cookies set by previous jsp page? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "servlet not finding the cookies set by previous jsp page?" Watch "servlet not finding the cookies set by previous jsp page?" New topic
Author

servlet not finding the cookies set by previous jsp page?

nick sharma
Greenhorn

Joined: May 05, 2008
Posts: 28
hello
i call a servlet from a jsp page in order for it to return me an image.everything was fine till i put in some way of recognising the user who is calling the servlet for the image, by reading a cookie already set in the jsp page when the user logs in.i use the following code to recognise the user



intrestingly the servlet sets the session right and prints the username attribute right but doesnt get the cookies even though the system has cookies.
whats the problem??
[ June 25, 2008: Message edited by: Bear Bibeault ]
nick sharma
Greenhorn

Joined: May 05, 2008
Posts: 28
hello can ny1 please help me with the problem??
Ben Souther
Sheriff

Joined: Dec 11, 2004
Posts: 13410

Two things.

Patience is a virtue. Adding more posts to your thread only increases the chance that others will already think it's been answered and not bother reading it.

Use real words when posting to the ranch. Many people use language translation software to read posts here and will not understand what "ny1" means.


Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: servlet not finding the cookies set by previous jsp page?
 
Similar Threads
Using a method to retrieve a cookie
Doubt regarding the cookies.
Cookie maxAge problem
creating secure Java apps
Testing Cookies