Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

forwarding request to new servlet with cookies

Status
Not open for further replies.

vulcand4

Programmer
Jul 29, 2003
76
US
I am using the forwarding capabilites of Java Servlets to forward a request from one servlet to another based on some input criteria.

The first servlet builds a cookie and normally sends it in the response back to the user. Then when the user sends a new request, the cookie gets sent along to servlet number 2.

Since I am forwarding the request (in one specific instance) from servlet 1 to servlet 2 without going back to the user, is there a way to build a cookie and place it in the request object so that the second servlet will see it?

Basically, I need the second servlet to think that the request came from the user as opposed to coming from servlet 1.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top