Print Page | Close Window

Redirecting to Two Different Pages

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: Classic ASP Discussion
Forum Description: Discussion on Active Server Pages (Classic ASP).
URL: https://forums.webwiz.net/forum_posts.asp?TID=13094
Printed Date: 30 March 2026 at 7:50pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Redirecting to Two Different Pages
Posted By: Misty
Subject: Redirecting to Two Different Pages
Date Posted: 23 December 2004 at 12:14am
I have an ASP Page that I would like to be redirected to two different web pages. Does anyone know if it is possible to redirect the web page to two different web pages at the same time?
 
I would like for the ASP page to redirect to the following pages:
 

<1.) a href="javascript:OpenNewWindow('<%=page%>')">View <%= PageName%> </a>

 
2.) Response.redirect "staff.asp" (this is correct)
 
Can someone please help me with the code? The 1st one opens in a new window. <%= PageName%>



Replies:
Posted By: ivek
Date Posted: 23 December 2004 at 6:52pm
Use JavaScript

<html>
<title></title>
<head>
<script LANGUAGE="JavaScript">
function opennewwin() {
window.open("http://www.something.net/", "_blank");
}

function gothere() {
window.location.href= "http://www.something.com";
}
</script>
</head>
<body onload="opennewwin();gothere()">
</body>
</html>

If you're using strings to read the address, you can modify script and enter your values like:
change window.location.href= "http://www.something.com"; to window.location.href= "<%=string%>";


Posted By: Misty
Date Posted: 26 December 2004 at 1:55am
ivek, thank you for the code! It worked.



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net