HELP!! I am a VB programer that has been 'Thrown in at the deep end' to get a web server working with asp/javascript elements and I am having to scavange code from various sources which is not fitting together. Here is my problem...
I have a web page that has various buttons(in javascript) that hyperlink to a page with a variable which (naturally) changes according to which button is pressed.
eg button 1 gives button 2 gives
This works fine. What I am having problems is that I then want to forward the user onto a different page depending on which button they have pressed.
If the clicked on button 1 they should go to , and button 2 should go to
I am using this at the top to read in the refer code
<%Option Explicit%>
<%
dim referree
referree = Request.QueryString("referree"
session("referree" = referree
%>
which puts it as a session variable named referree. Then in the <HTML> section I have this code which sets up the function nextpage()
<head>
<meta http-equiv="Content-Language" content="en-gb">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<script language="JavaScript">
<!--
function nextPage(){
var sReferree, sDestination
sReferree==Request.QueryString("referree"
if (sReferree=="1"{
sDestination == ;
}
if (sReferree=="2"{
sDestination == ;
}
var nextAddr = "window.location=sDestination;";
setTimeout(nextAddr,100);
}
//-->
</script>
Finally in the <BODY> section I have
<body onLoad="nextPage();">
to call the function.
Can anyone tell me where I am going wrong.
Eternally gratefull
Garty
I have a web page that has various buttons(in javascript) that hyperlink to a page with a variable which (naturally) changes according to which button is pressed.
eg button 1 gives button 2 gives
This works fine. What I am having problems is that I then want to forward the user onto a different page depending on which button they have pressed.
If the clicked on button 1 they should go to , and button 2 should go to
I am using this at the top to read in the refer code
<%Option Explicit%>
<%
dim referree
referree = Request.QueryString("referree"
session("referree" = referree
%>
which puts it as a session variable named referree. Then in the <HTML> section I have this code which sets up the function nextpage()
<head>
<meta http-equiv="Content-Language" content="en-gb">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<script language="JavaScript">
<!--
function nextPage(){
var sReferree, sDestination
sReferree==Request.QueryString("referree"
if (sReferree=="1"{
sDestination == ;
}
if (sReferree=="2"{
sDestination == ;
}
var nextAddr = "window.location=sDestination;";
setTimeout(nextAddr,100);
}
//-->
</script>
Finally in the <BODY> section I have
<body onLoad="nextPage();">
to call the function.
Can anyone tell me where I am going wrong.
Eternally gratefull
Garty