user8484164
user8484164

Reputation:

Bootstrap font awesome icons not working when in downloaded CSS

I am running in a problem here. There are some bootstrap font awesome icons which are not working with the downloaded CSS but working with the same external CDN. Many are working but some are not working like fa-copyright, fa-credit-card-alt etc. For example:

Its working with

<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">

But not working when replace with

<link rel="stylesheet" href="css/font-awesome.min.css">

even though I copy the content of external CSS and replace with the contents of font-awesome.min.css in my css/ directory. Please help me.

Upvotes: 0

Views: 1598

Answers (3)

Paige
Paige

Reputation: 1

I came across the same problem. The version of FontAwesome I was using was outdated. I updated to use 4.7 and everything worked smoothly.

<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet">

Upvotes: 0

Eezo
Eezo

Reputation: 1771

It not work, that just the css. You need the font files of font-awesome too, and put them in a folder called fonts. The font files are:

  • FontAwesome.otf
  • fontawesome-webfont.eot
  • fontawesome-webfont.svg
  • fontawesome-webfont.ttf
  • fontawesome-webfont.woff
  • fontawesome-webfont.woff2

And you need the lastest versione too (4.7 i think) or you can't use some of the icons. Just go to their website and download it.

Upvotes: 0

omkara
omkara

Reputation: 982

try this:

<link href="//maxcdn.bootstrapcdn.com/font-awesome/4.1.0/css/font-awesome.min.css" rel="stylesheet">

or

<link src="http://maxcdn.bootstrapcdn.com/font-awesome/4.1.0/css/font-awesome.min.css" rel="stylesheet">

or

<link href="http://maxcdn.bootstrapcdn.com/font-awesome/4.1.0/css/font-awesome.min.css" rel="stylesheet">

You also need to download the fonts themselves as well...It is a font, like any other...So, go to fontawesome website, follow the instructions and download css + fonts.

Upvotes: 1

Related Questions