[thelist] MouseOver for graphical submit buttons?

Aylard JA (James) jaylard at equilon.com
Wed Jan 10 14:13:26 CST 2001


Aaron,

> I would like to use a MouseOver on a graphical submit button in my forms.

> Any ideas?

	This will work in IE 4+, Netscape 6, and Opera 5:

<form>
<input type="image" name="MyImage" src="MyImage.gif"
     onmouseover="this.src='YourImage.gif';"
     onmouseout="this.src='MyImage.gif';">
</form>

	Ideally, it is generally better practice to place your code within a
function rather than inline within the input element itself, but this gives
you the basic idea.

hth,
James Aylard




More information about the thelist mailing list