Gopinath
09-19-2003, 07:06 AM
What is the difference between
1. Server.Execute
2. Server.Transfer
3. Response.Redirect
4. inc file(SSI files)
Thankz
-gopi
rdoekes
09-19-2003, 08:23 AM
1 and 2:
Server.Execute executes an asp page within an asp page. After the called page is executed, asp continues with the rest of the calling page
Server.Transfer transfers the control from the calling page to the called page, ignoring the rest of the code in the calling page.
Page1.asp
<% response.write "Hello World<br>"
Server.Execute("page2.asp")
Response.Write "Thank you, world"%>
page 2.asp
<% Response.Write "Insert me here!<br>"%>
Result :
Hello World,
Insert me here!
Thank you, world
Page1.asp
<% response.write "Hello World<br>"
Server.Transfer("page2.asp")
Response.Write "Thank you, world"%>
page 2.asp
<% Response.Write "Insert me here!<br>"%>
Result:
Hello World,
Insert me here!
Hope this helps,
-Rogier Doekes