J
JC
Hi,
I have a simple question regarding the Response.Redirect method. Does the
server stop processing the ASP code as soon as it encounters the Redirect
command? Or does it ever continue to process the page?
Basically, with the following code:
[....]
Response.Redirect("../newpage.asp")
Response.Write "This will crash: " & 1/0
It seems that the server sends the redirection header to the client as soon
as it hits the .Redirect line, and stops processing that page. I do not
receive a divide by zero error.
Is this always the expected behavior?
Also, someone mentioned in a previous thread that the correct syntax to use
is
Response.Redirect "http://someurl.com"
Response.End
What would happen if someone omitted to send a Response.End command?
Thanks in advance.
JC
I have a simple question regarding the Response.Redirect method. Does the
server stop processing the ASP code as soon as it encounters the Redirect
command? Or does it ever continue to process the page?
Basically, with the following code:
[....]
Response.Redirect("../newpage.asp")
Response.Write "This will crash: " & 1/0
It seems that the server sends the redirection header to the client as soon
as it hits the .Redirect line, and stops processing that page. I do not
receive a divide by zero error.
Is this always the expected behavior?
Also, someone mentioned in a previous thread that the correct syntax to use
is
Response.Redirect "http://someurl.com"
Response.End
What would happen if someone omitted to send a Response.End command?
Thanks in advance.
JC