In my table, I have a Font Awesome icon that I'm trying to align left with text and center the icons. I attempted to center the <i>
element but it didn't work as expected:
Here is the HTML code:
<td><i class="icon-ok"></i></td>
And here is the CSS code:
td, th {
text-align: left;
}
td i {
text-align:center;
}
You can view the jsFiddle for reference.
I also attempted to use text-align:center !important;
but it still didn't work. What am I doing wrong?