Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

difference between forward and sendredirect

Answer Posted / dsr

FORWARD-->
1. THE REQUEST AND RESPONSE OBJECT REMAIN SAME.
2. CONTROL DIRECTLY GOES TO REQUESTED PAGE AT THE POINT
WHERE FORWARD IS CALLED.
3. REQUEST DISPATCHER IS NEEDED.
4.forward() is used to transfer the request within the web
application

SEND REDIRECT:--->
1.NEW REQUEST AND RESPONSE IS GENERATED IN CASE THIS CASE.
2.IN THIS CASE FIRST CONTROL GOES TO CLIENT(BROWSER) AND
THEN TO REQUESTED PAGE.
3.JUST RESPONSE OBJECT IS NEEDED.
4.sendRedirect() is used to transfer the request from same
webapplication or different webapplication.

Is This Answer Correct ?    13 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the two important api's in for servlets?

1135


How a servlet is unloaded?

1133


Which java framework is most popular?

1212


What is the requirement of servlet config and servlet context implemented and how are they implemented?

1047


What is the difference between 2 types of servlets?

1193


What are the life-cycle methods for a servlet?

1047


What do you mean by cgi and what are its drawbacks?

1027


Explain is servlet mapping?

1056


What is getservletcontext?

1135


What are Servlets?

1180


What is setattribute in servlet?

1216


Difference between GET and POST?

1217


How do we share data using 'getservletcontext ()?

1092


How to get the path of servlet in the server?

1047


Explain web container.

1078