tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Asensio, Rodrigo" <rodrigo.asen...@gilbarco.com>
Subject RE: Forwarding based on URI's in Tomcat
Date Wed, 01 Aug 2007 19:06:10 GMT
Are those 2 different webapps ?
If yes, you have to be aware of session data, diff webapps do not share
by default the session data.

But basically to do a client redirect you do this

Response.sendRedirect("otherURl")  >> this will change the url in the
client browser

To do a server redirect you can do either
<jsp:forward page="otherURL">

Or inside a servlet (or jsp)

request.getContext().getRequestDispatcher("otherURL").forward(request,re
sponse);


regards

-----Original Message-----
From: Mon Cab [mailto:futon33@yahoo.com] 
Sent: Wednesday, August 01, 2007 2:34 PM
To: Tomcat Usergroup
Subject: Forwarding based on URI's in Tomcat


I am trying to get tomcat to forward requests as follows

www.mysite.com/foo to direct to the foo action www.mysite.com/bar to
direct to bar action ie. bar.do

Does anyone have any pointers on this?  Sorry for the newbie question. 


       
________________________________________________________________________
____________
Looking for a deal? Find great prices on flights and hotels with Yahoo!
FareChase.
http://farechase.yahoo.com/

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe,
e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org



This message (including any attachments) contains confidential 
and/or proprietary information intended only for the addressee.  
Any unauthorized disclosure, copying, distribution or reliance on 
the contents of this information is strictly prohibited and may 
constitute a violation of law.  If you are not the intended 
recipient, please notify the sender immediately by responding to 
this e-mail, and delete the message from your system.  If you 
have any questions about this e-mail please notify the sender 
immediately. 

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message