Reputation: 441
Suppose to have a fa icon:
//this code is not correct
<i class="fa fa-trophy fa-3x" aria-hidden="true" style="background-color:#FFFF00;"></i>
My purpose is to color the trophy itself and not the backgroud outside the trophy. Now the trophy it appears me black how can I change trophy color in yellow?
Upvotes: 0
Views: 321
Reputation: 147
fa icon is a font. Please use color property for this.
<i class="fa fa-trophy fa-3x" aria-hidden="true" style="color:#357ebd;"></i>
Upvotes: 0
Reputation: 703
Use the color property for fa icons.
<i class="fa fa-trophy fa-3x" aria-hidden="true" style="color:yellow;"></i>
Upvotes: 3
Reputation: 2859
Font awesome is a font - use the CSS color property to change the color, rather than background-color.
<i class="fa fa-trophy fa-3x" aria-hidden="true" style="color: #ffff00;"></i>
Upvotes: 7