|
|
 |
Re: FN-FORUM rollover
date posted 19th June 2002 10:44
This is a multi-part message in MIME format.
------=_NextPart_000_0049_01C2177E.C8CFE0A0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Pam,
Javascript differences between Netscape 4 and IE are especially a =
nightmare when it comes to Layers, since Netscape sets up an entire new =
document for each layer.
This means that, because it's inside a div, the image has to be =
referenced as document.layers['rollover'].document.images['send']
the easiest thing to do (I imagine) is get rid of the div, and putting =
the event handlers into an image tag.
try replacing your code with the following:
nb. this will submit the first (id=3D0) form on your page. If this isn't =
the only form, give it a name and change the onClick to =
document.forms['myFormName'].submit();
Hope this helps
Warren
----- Original Message -----=20
From: PAMELA WHITTAKER=20
To: [EMAIL REMOVED]
Sent: Wednesday, June 19, 2002 9:22 AM
Subject: FN-FORUM rollover
Hi again,
This is the code that doesn't work for Netscape. If someone can =
tell me why I would be grateful.
Pam
------=_NextPart_000_0049_01C2177E.C8CFE0A0
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Pam,
Javascript =
differences between=20
Netscape 4 and IE are especially a nightmare when it comes to Layers, =
since=20
Netscape sets up an entire new document for each layer.
This means that, because it's inside a =
div, the=20
image has to be referenced as=20
document.layers['rollover'].document.images['send']
the easiest thing to do (I imagine) is =
get rid of=20
the div, and putting the event handlers into an image tag.
try replacing your code with the=20
following:
<img src=3D"images/submitbut.gif" =
alt=3D"Submit"=20
border=3D"0" width=3D"64" height=3D"22" =
onMouseOut=3D"alert('g');MM_swapImgRestore()"=20
onMouseOver=3D"alert('ccc');MM_swapImage('send','','images/submitroll.gif=
',3)"=20
onClick=3D"document.forms[0].submit();">
nb. this will submit the first (id=3D0) =
form on your=20
page. If this isn't the only form, give it a name and change the onClick =
to=20
document.forms['myFormName'].submit();
Hope this helps
Warren
----- Original Message -----
From:=20
|
 |
|