DiaH
02-12-2003, 04:22 PM
I have this code at the top of my html page:
function window_onload() {
var strURL;
var strLowerURL;
var strMenuSwap;
strURL=document.referrer;
strLowerURL=strURL.toLowerCase();
alert(strLowerURL);
if(strLowerURL.search(/soh/)>-1)
{ //is public
strMenuSwap='../../soh/Scripts/menu_var.js';
}
else
{ //is internal
strMenuSwap='../../soh_internal/Scripts/menu_var.js';
}
}
I want to use the variable strMenuSwap in the html code where it calls the external js file. I thought I knew how to do this but I can't figure it out.
Any help is appreciated!!!
Dia
function window_onload() {
var strURL;
var strLowerURL;
var strMenuSwap;
strURL=document.referrer;
strLowerURL=strURL.toLowerCase();
alert(strLowerURL);
if(strLowerURL.search(/soh/)>-1)
{ //is public
strMenuSwap='../../soh/Scripts/menu_var.js';
}
else
{ //is internal
strMenuSwap='../../soh_internal/Scripts/menu_var.js';
}
}
I want to use the variable strMenuSwap in the html code where it calls the external js file. I thought I knew how to do this but I can't figure it out.
Any help is appreciated!!!
Dia