Response Redirect doesn't Work - No me funciona Response Redirect 
Author Message
 Response Redirect doesn't Work - No me funciona Response Redirect

English
Response.Redirect is not responding, what is wrong in the script please? The
browser shows a "Expected statement" error

Spanish
El Mtodo Response.Redirect no funciona, muestra un mensaje de error en la
lnea correspondiente diciendo que se esperaba una declaracin.


<HTML>
<% Mensaje = Request.ServerVariables("QUERY_STRING")%>
<%If Mensaje = "" Then %>
<% nuevaDir = " http://www.*-*-*.com/ ;
<%Response.Redirect nuevaDir %>       <---- this is the error line / esta es
la lnea
<%Else %>
<% Response.Write ("You are In") %>
<%End if %>

</HTML>

thank you
gracias



Sat, 07 Dec 2002 03:00:00 GMT  
 Response Redirect doesn't Work - No me funciona Response Redirect
You can't write to a file when your redirecting to another.

--
Dominic



Sat, 07 Dec 2002 03:00:00 GMT  
 Response Redirect doesn't Work - No me funciona Response Redirect
Move your opening <HTML> tag below the Response.Redirect.  You can't
response.redirect once the HTTP headers have been written to the client.

- Jeff


Quote:
> English
> Response.Redirect is not responding, what is wrong in the script please?
The
> browser shows a "Expected statement" error

> Spanish
> El Mtodo Response.Redirect no funciona, muestra un mensaje de error en la
> lnea correspondiente diciendo que se esperaba una declaracin.


> <HTML>
> <% Mensaje = Request.ServerVariables("QUERY_STRING")%>
> <%If Mensaje = "" Then %>
> <% nuevaDir = "http://www.domain.com/members.htm"
> <%Response.Redirect nuevaDir %>       <---- this is the error line / esta
es
> la lnea
> <%Else %>
> <% Response.Write ("You are In") %>
> <%End if %>

> </HTML>

> thank you
> gracias



Sat, 07 Dec 2002 03:00:00 GMT  
 Response Redirect doesn't Work - No me funciona Response Redirect
Unless it's just a typo in the post, you're missing the closing %> in the line preceding the error.

You also need to add Response.Buffer = True at the top or move the opening <HTML> tag below the
redirect...

--
Michael Harris
MVP Scripting

English
Response.Redirect is not responding, what is wrong in the script please? The
browser shows a "Expected statement" error

Spanish
El Mtodo Response.Redirect no funciona, muestra un mensaje de error en la
lnea correspondiente diciendo que se esperaba una declaracin.


<HTML>
<% Mensaje = Request.ServerVariables("QUERY_STRING")%>
<%If Mensaje = "" Then %>
<% nuevaDir = "http://www.domain.com/members.htm"
<%Response.Redirect nuevaDir %>       <---- this is the error line / esta es
la lnea
<%Else %>
<% Response.Write ("You are In") %>
<%End if %>

</HTML>

thank you
gracias



Sat, 07 Dec 2002 03:00:00 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. Response.Redirect not working after VBScript

2. Response.Buffer=false - still doesn't work

3. response.expires doesn't seem to work!

4. Response.Buffer=false - still doesn't work

5. Response.Redirect

6. Who called Response.Redirect?

7. response.redirect to a specific frame

8. Response.Redirect(someUrl) throws exception in Try Block

9. Response.redirect in frames

10. response.redirect

11. Response.Redirect and Validation Controls with ASP.NET

12. response.redirect

 

 
Powered by phpBB® Forum Software