SkylordRU1
Technical User
I have this Java Script Below. take a look it's a simple roll over trying to call the new image from the database.
<SCRIPT LANGUAGE="JScript">
Aregular = new Image; Aregular.src = "#rootMapping#navbarImages1/#pagelink#";
Ayellow = new Image; Ayellow.src = "#rootMapping#navbarImages/#pagelink#";
function MouseOverRoutine(ButtonName)
{
if (ButtonName=="button1"
{document.button1.src = Aregular.src;}
}
function MouseOutRoutine(ButtonName)
{
if (ButtonName=="button1"
{document.button1.src = Ayellow.src;}
}
</script>
The Links in my Navigation bar are images I call on the fly from the database with certain page #'s assigned to them by the #pagelink# assignment. I want to use the script above to comunicate the expression below.
<tr><td><a href="#pageURL#" onmouseOver="MouseOverRoutine('button1')" onmouseOut="MouseOutRoutine('button1')"><img src="#rootMapping#navbarImages/#pagelink#" Border="0" width="180" height="21"></a><br></td></tr>
Everything works but the Java Script it keeps telling me that the document.button1 is not an object.
Can anyone help?
<SCRIPT LANGUAGE="JScript">
Aregular = new Image; Aregular.src = "#rootMapping#navbarImages1/#pagelink#";
Ayellow = new Image; Ayellow.src = "#rootMapping#navbarImages/#pagelink#";
function MouseOverRoutine(ButtonName)
{
if (ButtonName=="button1"
{document.button1.src = Aregular.src;}
}
function MouseOutRoutine(ButtonName)
{
if (ButtonName=="button1"
{document.button1.src = Ayellow.src;}
}
</script>
The Links in my Navigation bar are images I call on the fly from the database with certain page #'s assigned to them by the #pagelink# assignment. I want to use the script above to comunicate the expression below.
<tr><td><a href="#pageURL#" onmouseOver="MouseOverRoutine('button1')" onmouseOut="MouseOutRoutine('button1')"><img src="#rootMapping#navbarImages/#pagelink#" Border="0" width="180" height="21"></a><br></td></tr>
Everything works but the Java Script it keeps telling me that the document.button1 is not an object.
Can anyone help?