Background Image for Input Button with CSS (works in both Firefox and IE)
Posted on September 6, 2008 by Balaji Ramesh
I was having trouble with setting a background image for an input button in IE 6. The background-image property that worked in Firefox 2.0 just did not have any effect on IE6. After a bit of googling, I realized that the background-image property will not work on IE and that we need to use the background property. Here’s a snippet that works on both browsers:
.button{
background: white url(‘images/imagebutton.gif’) no-repeat top;
width: 150px;
height: 40px;
color:white;
}
Tags: IEHacks