Astro
Astro

Reputation: 133

Font Awesome - Change color - "&#xf0c7" format

I know it's easy to change the color if you use the standard format and css :

<i class="icon-cog"></i>

But I'm forced to use the html format (&#xf0c7) of the icon:

<input id="btn-save-workout" type="submit" class="btn btn-default pull-right btn-sm" value="&#xf0c7; Save"> 

http://fortawesome.github.io/Font-Awesome/cheatsheet/

Not sure it's possible with this syntax. I tried putting a div around with a color without success. Thanks in advance,

Upvotes: 0

Views: 393

Answers (1)

Antrikshy
Antrikshy

Reputation: 3106

Try this:

<button id="btn-save-workout" type="submit" class="btn btn-default pull-right btn-sm">&#xf0c7; Save</button>

Functionally, <button type="submit">Submit</button> is identical to what you are doing.

Then change the color on that button.

Here's some information on button vs input.

Upvotes: 1

Related Questions