How do I change this to a response.redirect please?
<A HREF="default.asp?fname=<%=filename%>">Continue</A>
Thanks in advance.
Printable View
How do I change this to a response.redirect please?
<A HREF="default.asp?fname=<%=filename%>">Continue</A>
Thanks in advance.
This is HTML :Quote:
Originally posted by Klas
How do I change this to a response.redirect please?
<A HREF="default.asp?fname=<%=filename%>">Continue</A>
Thanks in advance.
<A HREF="default.asp?fname=<%=filename%>">Continue</A>
This is server-side scripting :
<%
Response.Redirect("http://www.google.com")
%>
Notice the diffence?
In addition, please explain what you're trying to do and post either URL or source, if possible.
Hi! :)
Sure I will. :)
I have
<A HREF="default.asp?fname=<%=filename%>">Continue</A>
at the end of a page where I have used JMAIL for uplaoding a file chosed by the user. The variable of the file is "filename".
And instead of clicking on Continue, I would like that the page default opends automaticly, and brings the filename in the url(as a querystring)
It works fine with the HTML link now, but it is a unnessecery(spelling?) step.
(ASP)
Best regards, Klas
For server side scripting (ASP), do this at the end of your script:
Although, be aware that the user will never see the page before the redirect occurs. So if you had some message for them there, they won't see it.Code:<%
Response.Redirect("default.asp?fname=" & filename)
%>
If you do want them to see such a message, you're better off doing a meta:
or client-side (javascript) script:Code:<META HTTP-EQUIV="Refresh" Content="10; URL =default.asp?fname=<%= filename %>">
redirect.Code:document.location = "default.asp?fname=<%= filename %>"