aspose file tools*
The moose likes Servlets and the fly likes cookies Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "cookies" Watch "cookies" New topic
Author

cookies

sitaram irrinki
Ranch Hand

Joined: Feb 16, 2005
Posts: 158
As we know that Headers and cookies set by a page
are not visible in forwarded and included pages. Then
how we can maintain the state in such type of
situations
stan ioffe
Greenhorn

Joined: Jun 30, 2005
Posts: 16
If you're submiting to a servlet that then redirects the request using a forward or an include, you can create session variables in the included servlets or you can create attributes using .setAttribute() method that can later on be retrieved from an HttpSesssion object on your final destination's page.

-stan
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: cookies