This week's book giveaway is in the OCAJP 8 forum.
We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line!
See this thread for details.
The moose likes JSP and the fly likes Difference between <jsp:forward> and RequestDispatcher Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "Difference between <jsp:forward> and RequestDispatcher" Watch "Difference between <jsp:forward> and RequestDispatcher" New topic

Difference between <jsp:forward> and RequestDispatcher

MaheshS Kumbhar
Ranch Hand

Joined: Sep 24, 2009
Posts: 188
I want to know the difference between <jsp:forward> standard action and RequestDispatcher as both are used to forward the request.

I am slow but sure
Jagdish Hatagale
Ranch Hand

Joined: Apr 07, 2010
Posts: 33
With RequestDispatcher you can pass the request object for next page,
means you pass the control and data with the help of RequestDispatcher, but with jsp:forward you cant sent the request object you just transfer the control to next page.
Venkata Kumar
Ranch Hand

Joined: Apr 16, 2008
Posts: 110

Both are same. When <jsp:forward> is translated to servlet then requestdispatcher is used to forward the request.

SCJP 5.0, SCWCD 5, preparing for SCDJWS
I agree. Here's the link:
subject: Difference between <jsp:forward> and RequestDispatcher
jQuery in Action, 3rd edition