Classic ASP Response.redirect

2019-07-20 01:07发布

I wish to redirect a user to another page after logon.

The code below:

Response.Redirect("../agent/info.asp")

works fine - for Safari, IE, and Chrome. Not Firefox.

The code below:

Response.Redirect("agent/info.asp")

works in Firefox, but nothing else.

标签: asp-classic
1条回答
Anthone
2楼-- · 2019-07-20 01:39

If the page you are redirecting to isn't in the same directory, you're generally better off using either the full URL or the full virtual path like so (assuming /agent/ is in a directory below the root like what your example implies):

Response.Redirect("/agent/info.asp")

or

Response.Redirect("http://www.example.com/agent/info.asp")

More information and examples can be found at MSDN.

查看更多
登录 后发表回答