Forums Register Login

Usage of sendRedirect()?

+Pie Number of slices to send: Send
Hi All,

sendRedirect() method is working with client...so if you redirect to B.jsp

still you able to access session in B.jsp!!! but you can not access request object!!

please anyone can tell me the usage of sendRedirect()

thanks & regards,
seetharaman
[ April 27, 2008: Message edited by: David O'Meara ]
+Pie Number of slices to send: Send
sendRedirect() sends a message to the browser asking it to load the new link, which may be either local or remote.

Consider the following, which processes some data then displays the menu page:

Once they get back to the main page, if they reload the page the original form gets called and processes the data again when the person just wanted to refresh the page. The display is still coupled with the previous processing.

If the client reloads, they get the index page again.
+Pie Number of slices to send: Send
FYI, Bear removed the multiple exclamation marks from your topic, I re-edited to make it meaningful.
+Pie Number of slices to send: Send
Thanks a lot, David O'Meara
+Pie Number of slices to send: Send
sendRedirect() method is use for sending new request to the client.
A sonic boom would certainly ruin a giant souffle. But this tiny ad would protect it:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 744 times.
Similar Threads
Session in jsp
Mapping JSP
Session persist when server shuts down?
Confusion on page directive in spec
session invalidate?
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 29, 2024 00:09:07.