tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Rees" <dr...@ebetinc.com>
Subject RE: response.sendRedirect bug or feature
Date Thu, 07 Dec 2000 17:05:26 GMT
Add a return statement:

if (a > b) {
	response.sendRedirect(url1);
	return;
}
// Do something else!
response.sendRedirect(url1);

-Dave

> -----Original Message-----
> From: zk@t-online.de [mailto:zk@t-online.de]On Behalf Of Zsolt Koppany
> Sent: Thursday, December 07, 2000 12:30 AM
> To: tomcat-user@jakarta.apache.org
> Subject: response.sendRedirect bug or feature
> 
> 
> Hi,
> 
> I think it might have been changed since tomcat-3.2-beta-6 but now when
> I execute a  response.sendRedirect(..) the rest of the jsp file is still
> executed. How can I prevent that?
> 
> My example:
> 
> ....
> if (a > b)
> {
>     response.sendRedirect(url1);
>    // Here I don't want to proceed this jsp file because url1 creates a
> complete page on its own.
> }
> 
> // Let's do somthing else!
> ...
> response.sendRedirect(url2);
> 
> 
> Zsolt
> -- 
> Zsolt Koppany
> Intland GmbH www.intland.com
> Schulze-Delitzsch-Strasse 16
> D-70565 Stuttgart
> Tel: +49-711-7871080 Fax: +49-711-7871017

Mime
View raw message