Friday, November 30, 2012

Image Background Position not working in Firefox, CSS Style Sheet

Image Background Position not working in Firefox, CSS Style Sheet

If you are facing issues to set Image background position with following style sheet class
display: inline-block;
border: none;
background-image: url(/images/MockIcon.png);
background-repeat: no-repeat;
background-position-x: 50px;
background-position-y: 5px;
vertical-align: middle;

 Try following style sheet class which will work in all the Browsers (Chrome, IE and Firefox)
display: inline-block;
border: none;
background-image: url(/images/MockIcon.png);
background-repeat: no-repeat;
background-position: left 50px top 5px;
vertical-align: middle;
 

No comments: