What is difference between Forward() and sendRedirect()
methode?
Answer Posted / n.muthukumar
sendRedirect() sends a redirect response back to the
client's browser.
forward() does not involve the client's browser.
The forward( ) is faster than Sendredirect( ).
RequestDispatcher.forward( ) works on the Server.
when you use send redirect it will rediredct the url to new
url and It will be displayed in browser.
response.sendRedirect(http://162.1.1.0/error.html);
When you use forward it will forward to particular page but
in browser forwarded url won't dispaly
<jsp:forward page http://162.1.1.0/error.html) />
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
Name the packages that work with servlet?
What methods do you use in servlet - applet communication?
Define the life cycle of a servlets.
What are different ways for servlet authentication?
What is http servlet in java?
The code in a finally clause will never fail to execute, right?
Can we use threads in Servlets?
Why session tracking is needed?
What are session variable in servlets?
How servlet is created?
Describe servlet?
What are the kinds of http requests?
Is servlet thread safe?
Explains the differences between context.getrequestdispatcher() and request.getrequestdispatcher()?
How does tomcat servlet container work?