Search code examples
asp.net-mvctwitter-bootstrapasp.net-mvc-4glyphicons

glyphicon icons not appearing in my MVC site having bootstrap implemented


Following is my HTML markup

<button class="btn btn-default" type="submit">
<i class="glyphicon glyphicon-camera"></i>
</button>

I have change following line variable.less

@icon-font-path:          "..\fonts";

the fonts folder contains four files - eot, svg, ttf and woff extension files for glyphicons-halflins

Following is how the folder structure is -

  • Content\bootstrap.css
  • Content\bootswatch.css
  • Content\variables.less
  • Contact\fonts-- all four files (extensions - eot, svg, ttf, and woff)

Any idea why it doesn't display icon in the webpage?

Any help on this much appreciated.


Solution

  • You used a backslash for specifying the path. Have you tried it with a forward slash? Have a look at Is there a way to set a common image path for LESS files?. All of them used forward slashes.