Videanu Adrian
Videanu Adrian

Reputation: 970

css not displayed correctly

I have the css made by one web designer, and that css file contains classes like :

    .icon-phone-alt:before {
        content: "\e064";
    }

and in my view page i have something like :

<span class="icon-phone-alt"></span>&#160;Tel.: (+40 21) XXXXXXXX<br />

The problem is that instead of something like this :
enter image description here

i get this:
enter image description here

I have to mention that my browser is configured to utf8 and the original html page is displayed correctly with the same browser. I think that this has something to do with character encoding but i do not know how to handle the situation.

Upvotes: 1

Views: 124

Answers (2)

artplastika
artplastika

Reputation: 1982

You have to use special font for icon span which displays icons as characters. For example:

<link rel="stylesheet" href="http://fortawesome.github.io/Font-Awesome/assets/font-awesome/css/font-awesome.css">
<span class="icon-phone"></span>&#160;Tel.: (+40 21) XXXXXXXX<br />

Upvotes: 1

maikelsabido
maikelsabido

Reputation: 1327

Maybe you have not included your Glyphicons/special fonts.

You should include them first. Try to look at this implementation:

https://github.com/mdo/bsu/blob/master/step-4/bootstrap-less/glyphicons.less

Upvotes: 1

Related Questions