I donβt think that using two different image elements on the icon is a good idea.
Single image element
src .
( ):
$(".side_left").mouseover(function() {
$(this).prop("src", "http://www.spiritualawakeningradio.com/yaha.jpg");
}).mouseout(function(){
$(this).prop("src", "http://img.creativemark.co.uk/uploads/images/461/13461/smallImg.png");
});
: DEMO
CSS
CSS . JavaScript , CSS:
.side_left {
width: 60px;
height: 60px;
background: url('http://i.imm.io/mvRL.png');
}
.side_left:hover {
background-position: 60px;
}
: DEMO