Edited:
I think you are trying to do as did in this DEMO
HTML
<input type="submit" value="" class="imgClass" />
THREE STATES OF BUTTON, NORMAL, HOVER, ACTIVE
CSS:
.imgClass {
background-image: url(http://inspectelement.com/wp-content/themes/inspectelementv2/style/images/button.png);
background-position: 0px 0px;
background-repeat: no-repeat;
width: 186px;
height: 53px;
border: 0px;
background-color: none;
cursor: pointer;
outline: 0;
}
.imgClass:hover{
background-position: 0px -52px;
}
.imgClass:active{
background-position: 0px -104px;
}
You need to use CSS Image Sprites for button states.
Ahsan Khurshid
- 9.5k
- 1
- 35
- 53