[thelist] Changing style.backgroundImage of a submit button in js?

Christian Heilmann codepo8 at gmail.com
Fri Jan 13 10:26:48 CST 2006


> <input type="submit" name="helpme" style="background: url('/images/btn-helpme.gif'); width: 351px; height: 80px; border: 0;" value="" onmouseover="kbutHitState(this);" />

> Does IE not support the access of the backgroundImage property on a submit input? The kluginess(tm) of this is just a-killin me.

You won't get lucky with styling form elements, you could use
JavaScript to replace it with a link though:
http://www.wait-till-i.com/index.php?p=211

Another option would be to use input type image, and use a transparent
image, but then you run into the issue that MSIE does not like :hover
on img.

--
Chris Heilmann
Blog: http://www.wait-till-i.com
Writing: http://icant.co.uk/
Binaries: http://www.onlinetools.org/



More information about the thelist mailing list