PDA

View Full Version : login button has rollover effect


Try_Try_Again
11-17-2002, 08:58 PM
I'm trying to make a login button (submit) that's an image have a rollover effect. Can anyone help me out with the following?

<form action="cgi_file">
<input type="image" src="something.gif" onMouseOver="this.src='different.gif';" onClick="this.form.submit();">
</form>

Where am I off here, 'cause the effect doesn't go away when I mouse Off it.

Any help would be appreciated!

beetle
11-17-2002, 09:27 PM
Well, of course it wouldn't without an onmouseout event! :D

<form action="cgi_file">
<input type="image" src="something.gif" onMouseOver="this.src='different.gif';" onMouseOut="this.src='something.gif';" onClick="this.form.submit();">
</form>

Try_Try_Again
11-17-2002, 09:35 PM
Nice!!!! Thanks Beetle! didn't even come across that :)