...

View Full Version : onmouseover error



hyefive
02-19-2003, 07:15 PM
Hi,

I'm trying unsuccessfully to implement an onmouseover effect that changes not only the image that's being rolled over, but another one on the page.

The error says "Expected (;)" (semicolon), which I can't seem to correct.

As you can tell I'm new to Javascript, so any help would be greatly appreciated!

Here's my code:

<head>
<script LANGUAGE="JavaScript" type="text/javascript">

e100=new Image(275,219);
e100.src="/images/diabloleft.jpg"
e200=new Image(274,206);
e200.src="images/office.jpg"
e101=new Image(275,219);
e101.src="images/diabloright.jpg"
e201=new Image(274,206);
e201.src="images/office.jpg"

function filter(imagename1,objectsrc1,imagename2,objectsrc2)
{
document.images[imagename1].src=eval(objectsrc1+".src");
document.images[imagename2].src=eval(objectsrc2+".src");
}

</script>
</head>

<body>
<table>
<tr>
<td><a href="feat3.asp?CID=BA6" onmouseover="filter('e300','e100','e400','101')" onmouseout="filter('e300','e200','e400','e201')">
<img src="images/office.jpg" NAME="e300"></td>

<td><img src="images/pixel.gif" width="5"></td>

<td><a href="about.htm">
<img src="images/office.jpg" NAME="e400"></td>
</tr>
</table>



Any ideas?
Thank you,
Mark

hyefive
02-19-2003, 07:39 PM
Posting to my own submission here... but a typo issue was causing my problem!

Thanks anyways,
Mark
:o



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum