What is the difference between sendRedirect() and forward()?
in what situations do we have to use send redirect()
instead of forward().
Answer Posted / aravind
forward() is a action element in jsp. it is used to pass
ctrl from current page to another jsp page and it is a
method in jsp.
send redirect() is a method in servlet.
there are two methods used. as
HttpServletResponse.encodeReDirctURL().which takes String
represents a redirction url.next sendredirect() method.
which takes the String returned from the
encoderedirectString() and send it back to the client for
redirection
Is This Answer Correct ? | 8 Yes | 10 No |
Post New Answer View All Answers
Explain j2ee architecture.
What is meant by applet in java?
What is javabeans component?
Why do we use j2ee?
What does the web module contain?
What is ejb container provider?
Is java more difficult than c++?
What is application client?
What is java naming and directory service?
What is java api for xml processing (jaxp)?
What is home handle?
What is core java and j2ee?
What is advance java?
What is Connector architecture?
What is java 2 platform, micro edition (j2me)?