What is the difference between sendRedirect() and forward()?
in what situations do we have to use send redirect()
instead of forward().
Answer Posted / vinit sharma
Hello i am vinit and according to me,
Both methods are use to transfer form one web component to
another web component.
In case of forward () the same request (that have client
information) is passed from server side to the another page
(this another page should be in the same container (Web
Server)), due to URL remains same.
While in sendRedirect () a new request (due to
loss the previous request information) is generated from
client side to another page (this another page can be in
the same OR in different container (Web Server)), due to
URL becomes change.
Is This Answer Correct ? | 7 Yes | 0 No |
Post New Answer View All Answers
What is java servlet container?
I Want build and release interview questions
What is difference between j2ee and java?
What does application client module contain?
Is java is a technology?
Is java more difficult than c++?
Hi Friends. I want complete technical flow of j2ee project with following technologies. jsp , servlet , Struts , Hibernate , (should follow mvc-2 design pattern) . with DAO ,DTO SERVICE layers .
Explain the four types of container that the j2ee specification defines
What is data?
What are the differences between Ear, Jar and War files? Under what circumstances should we use each one?
for example we are login into the irctc server from there it will go to the selected bank and deduct amount and come back to the irctc. so if we are developing this in java means will it be run on the same session. but as per my knowledge bank is separate and irctc is separate URL's so it will use two different sessions then how it is maintaining same session through out application and even it uses the payment gateway? how it is working can any one help me on that??
What is deployment descriptor?
What is digest authentication?
How do you compile java?
What is javaserver pages (jsp)?