-
OnMouseOver
Ok i cant seem to figure this out i have a mouseover working which changes a image but i would also like it to change the status bar with mouseover can anyone help.
Here is the relative code.
Code:
<SCRIPT LANGUAGE=JAVASCRIPT TYPE="TEXT/JAVASCRIPT">
<!-- Hide script from old browsers
if (document.images) {
menusep = new Image
menusep2 = new Image
menusep.src = "images/menusep.gif"
menusep2.src = "images/menusep2.gif"
}
else {
menusep = ""
menusep2 = ""
document.arrow = ""
document.arrow1 = ""
document.arrow2 = ""
document.arrow3 = ""
document.arrow4 = ""
document.arrow5 = ""
document.arrow6 = ""
document.arrow7 = ""
document.arrow8 = ""
}
// End hiding script from old browsers -->
</SCRIPT>
<A target=main onMouseOver="document.arrow.src=menusep2.src" onMouseOut="document.arrow.src=menusep.src" id="menucontent" HREF="http://www.tomowebsite.com/fc3/main.php">Home</A><BR>
<IMG SRC="images/menusep.gif" WIDTH="120" HEIGHT="4" BORDER=0 ALT="" name="arrow"><BR>
-
The javascript to change the status bar is:
window.status='text here'
You can seperate commands in an onMouseOver="" bit with semicolons. Hence the following code should work:
Code:
<a target="main"
onMouseOver="document.arrow.src=menusep2.src;window.status='some text';"
onMouseOut="document.arrow.src=menusep.src;window.status='';"
id="menucontent"
href="http://www.tomowebsite.com/fc3/main.php">Home</a>
I split the code on to seperate lines for readability - it should still be valid HTML but you can get rid of the newlines if you like.
-