what is difference between redirect and forward method?
Answer Posted / vipin gupta trainer
There is a difference between the
HttpResponse.sendRedirect() method and the
RequestDispatcher.foward() method .
the sendRedirect() method leverage Https built in redirect
features to send a message back to the client and foce the
visitors Browser to request a new page .
the forward() method transfer the HttpServletRequest and
HttpServletResponse methods to the indicated file on the
web server. the forward() method never communicates with
the visitors browser .
| Is This Answer Correct ? | 19 Yes | 3 No |
Post New Answer View All Answers
What is session getattribute in jsp?
Which jsp methods can be overridden?
What is a page directive?
How can we avoid direct access of jsp pages from client browser?
Is jsp front end or backend?
Explain the difference between servlet and jsp?
How can we forward the request from jsp page to the servlet?
What is cookie with example?
How to include a jsp file in another jsp file?
Why jsp is faster than servlet?
What is the page directive is used to prevent a jsp page from automatically creating a session?
How many jsp implicit objects are there?
How can we extend jsp technology?
What is jspinit method?
How jsp is executed?