Server.Transfer Response.Redirect
Redirection Redirection is done by the server. Redirection is done by the browser client.
Browser URL Does not change. Changes to the redirected target page.
When to use Redirect between pages of the same server. Redirect between pages on different server and domain.
Response.redirected:
We can bookmark the page because the full address is shown in a browser URL.
An extra round trip happens to the server.
It is used in HTML, ASP and ASP.Net pages to navigate from one page to another.
server.transfer:
We cannot bookmark the page because the full address is not shown in a browser URL.
An extra round trip does not happen to the server; because of this it saves server resources.
It is only used to navigate within an ASP or ASP.Net page, not within HTML pages.
=================================================================================================================
Response.Redirect(URL,true) vsResponse.Redirect(URL,false) ?
Response.Redirect(URL,false): Client is redirected to a new page and the current page on the server will keep processing ahead.
Response.Redirect(URL,true): Client is redirected to a new page but the processing of the current page is aborted.
=====================================================================================================================
No comments:
Post a Comment