Click here to Skip to main content
15,898,538 members
Home / Discussions / Java
   

Java

 
AnswerRe: what is the difference between sendRedirect() and forward()? Pin
Sandeep Mewara11-Mar-13 20:44
mveSandeep Mewara11-Mar-13 20:44 
forward: Control can be forward to resources available within the server from where the call is made. This transfer of control is done by the container internally and browser / client is not involved. This is the major difference between forward and sendRedirect. When the forward is done, the original request and response objects are transfered along with additional parameters if needed.

redirect: Control can be redirect to resources to different servers or domains. This transfer of control task is delegated to the browser by the container. That is, the redirect sends a header back to the browser / client. This header contains the resource url to be redirected by the browser. Then the browser initiates a new request to the given url. Since it is a new request, the old request and response object is lost.

More details here: http://javapapers.com/jsp/difference-between-forward-and-sendredirect/[^]
Sandeep Mewara
Microsoft ASP.NET MVP 2012 & 2013

[My Blog]: Sandeep Mewara's Tech Journal!
[My Latest Article]: HTML5 Quick Start Web Application

AnswerRe: what is the difference between sendRedirect() and forward()? Pin
vkscool24-Mar-13 21:01
vkscool24-Mar-13 21:01 
QuestionHow to use time picker in jsp? Pin
Phyo Thinzar Aung10-Mar-13 23:26
Phyo Thinzar Aung10-Mar-13 23:26 
AnswerRe: How to use time picker in jsp? Pin
Richard MacCutchan10-Mar-13 23:39
mveRichard MacCutchan10-Mar-13 23:39 
AnswerRe: How to use time picker in jsp? Pin
Shubhashish_Mandal14-Mar-13 0:26
professionalShubhashish_Mandal14-Mar-13 0:26 
QuestionHelp For Creating JSP invoice Pin
eMaM1519878-Mar-13 23:37
eMaM1519878-Mar-13 23:37 
AnswerRe: Help For Creating JSP invoice Pin
Richard MacCutchan10-Mar-13 23:37
mveRichard MacCutchan10-Mar-13 23:37 
QuestionAudio Sample Playback Pin
dusty_dex7-Mar-13 15:46
dusty_dex7-Mar-13 15:46 
AnswerRe: Audio Sample Playback Pin
Richard MacCutchan7-Mar-13 21:58
mveRichard MacCutchan7-Mar-13 21:58 
Questionjtds connection problem.... SQL Server 2012 Express Pin
MacRaider47-Mar-13 3:22
MacRaider47-Mar-13 3:22 
AnswerRe: jtds connection problem.... SQL Server 2012 Express Pin
MacRaider47-Mar-13 7:03
MacRaider47-Mar-13 7:03 
AnswerHibernate Data base connection lost Pin
kvsravindrareddy12-Mar-13 21:04
kvsravindrareddy12-Mar-13 21:04 
SuggestionRe: jtds connection problem.... SQL Server 2012 Express Pin
Prasad Khandekar2-May-13 20:12
professionalPrasad Khandekar2-May-13 20:12 
QuestionRetails invoice Pin
eMaM1519877-Mar-13 0:39
eMaM1519877-Mar-13 0:39 
AnswerRe: Retails invoice Pin
Sandeep Mewara7-Mar-13 1:24
mveSandeep Mewara7-Mar-13 1:24 
Questionjava help Pin
okedi5-Mar-13 22:15
okedi5-Mar-13 22:15 
AnswerRe: java help Pin
Richard MacCutchan5-Mar-13 22:22
mveRichard MacCutchan5-Mar-13 22:22 
Questiondemende help Pin
لحن الأماني5-Mar-13 9:50
لحن الأماني5-Mar-13 9:50 
AnswerRe: demende help Pin
Master.Man19805-Mar-13 10:21
Master.Man19805-Mar-13 10:21 
Questiondemende help Pin
لحن الأماني5-Mar-13 9:50
لحن الأماني5-Mar-13 9:50 
AnswerRe: demende help Pin
dusty_dex6-Mar-13 4:52
dusty_dex6-Mar-13 4:52 
Questiondemende d'aide Pin
لحن الأماني5-Mar-13 8:17
لحن الأماني5-Mar-13 8:17 
AnswerRe: demende d'aide Pin
Jibesh5-Mar-13 8:47
professionalJibesh5-Mar-13 8:47 
SuggestionRe: demende d'aide Pin
Richard MacCutchan5-Mar-13 9:46
mveRichard MacCutchan5-Mar-13 9:46 
GeneralRe: demende d'aide Pin
dusty_dex6-Mar-13 0:31
dusty_dex6-Mar-13 0:31 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.