This week's book giveaway is in the JDBC forum.
We're giving away four copies of Make it so: Java DB Connections & Transactions and have Marcho Behler on-line!
See this thread for details.
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes Question From ScwcdHints..? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Make it so: Java DB Connections & Transactions this week in the JDBC forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "Question From ScwcdHints..?" Watch "Question From ScwcdHints..?" New topic

Question From ScwcdHints..?

Manwatkar Vaibhav

Joined: Jun 11, 2007
Posts: 26
From ScwcdHints :

A <jsp:forward> effectively terminates the current page. Nothing before the <jsp:forward> or after the <jsp:forward> is written to the response! It is not the same when using a requestDispatcher.forward().

Does it mean, if I use requestdispatcher to forward request to another web component, the output before calling next component or after calling next component will be displayed as output..?

Clarify me please..

Regards,<br />---------<br />Vaibhav<br />SCJP 1.4<br />SCWCD 1.4<br />---------
Mirko Bonasorte
Ranch Hand

Joined: May 14, 2007
Posts: 244
from the specs,

a jsp : forward effectively terminates the execution of the current page

This means that if you do something other than printing after forwarding (for example, committing data to the database), it is not executed.

SCJP<br />SCWCD 1.4 Upgrade (Remember: me stupid)<br />SCWCD 1.4<br /><a href="" target="_blank" rel="nofollow">SCBCD 5.0</a><br /><a href="" target="_blank" rel="nofollow">SCBCD 5.0 mock exam</a> <br /> <br />SCEA 5 Part1: Preparing...
I agree. Here's the link:
subject: Question From ScwcdHints..?
It's not a secret anymore!