| Author: sri 07 Nov 2009 | Member Level: Silver | Rating:  Points: 2 |
Response.Redirect sends a message to the browser, telling it to move to another page.
Server.Transfer is similar in that it sends the user to another page
Thanks & Regards sri
|
| Author: krishnavenikaladi 07 Nov 2009 | Member Level: Gold | Rating:    Points: 6 |
server.transfer transfers page processing from one page directly to the next page without making round trip back to clients browser. this provides faster response but can't update the clients url historylist. response.transfer is used to redirect users browser to another page/site.this performs a round trip.this updates the clients url history list
|
| Author: Deepika Haridas 07 Nov 2009 | Member Level: Diamond | Rating:  Points: 2 |
Hello,
Response.Redirect performs a roundtrip to server which means when you re-direct the page your URL changes too. In server.transfer it transfers the contents of other page in same page and also URL doesn't change.
For example, If you write Response.Redirect("http://yahoo.com"); - This will re-direct to Yahoo site whereas Server.Transfer("http://yahoo.com"); - This line will give an error (As server.Transfer will only work in your application scope)
Thanks & Regards, Deepika Editor
If U want to shine like a SUN..First U have to burn like the SUN!! Need a Guide? Join my mentor program..
|
| Author: Shivraj Singh Rajawat 07 Nov 2009 | Member Level: Bronze | Rating:  Points: 2 |
Server.Transfer() does not change URL of the brower......
|
| Author: Nikhil Gaur 07 Nov 2009 | Member Level: Diamond | Rating:  Points: 2 |
Response.Redirect() will redirect you to your destination page and will change client browser address bar with new URL.
but Response.Transfer will only redirect you without changing the url at client browser. but remember if you use server.transfer two times continuously means first you use server.Transfer("default.aspx") and in default.aspx you use Response.Transfer("default2.aspx") then it will not show the initial url when you are in default2.aspx but it will show default.aspx.
Join this campus group http://www.dotnetspider.com/sites/637/-ecb-aspdotnet.aspx
Thanks & Regards NIks My Software and Web Development Experience
|
| Author: Bunty 09 Nov 2009 | Member Level: Diamond | Rating:  Points: 2 |
Hi,
1>Response.redirect sends message to the browser saying it to move to some different page while Server.transfer does not send any message to the browser but rather redirects the uyser directly from the server itself.So in Server.transfer their is no round trip while Response.redirect has a round trip hence puts a load on the server.
2>Using Sever.transfer you cannot redirect to a different server itself while using Response.redirect you can redirect to a different server also.
3>With Server.transfer you can preserve your information.It has a parameter called as "preserve form",so the existing query string etc will be available in the calling page.This is not possible in Response.redirect.
Thanks & Regards S.S.Bajoria
|