I’ve created an element a h4
element which the :before
pseudo element to insert an icon font (generated at IcoMoon). The h4
element is set to text-align: center;
and the icons are set to display: block;
so that they also center. Perfect!
The problem is in IE8. The h4
elements are centered but the icons inserted using :before
are left-aligned. I’ve tried giving the before element a text-align: center
property and I also tried applying:
display: block;
width: 80px;
margin: 0 auto;
Now I don’t know what to try next. Here is the code for the icons:
[class^="ico-fonts-"]:before,
[class*=" ico-fonts-"]:before {
font-family: @icoFont;
font-style: normal;
speak: none;
font-weight: normal;
line-height: 1;
}
Any suggestions would be appreciated! :-)