Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
jdh
12,334 PointsWeb Font for CSS Not Working
I'm trying to load this font that I found. I have the files in my "font" folder and have included the below in my CSS but it wont load. I am also using Bootstrap. Any thoughts why?
@font-face {
font-family: 'Chevin-Light';
src:url("../font/chevinstd-light-webfont.eot");
src: url("../font/chevinstd-light-webfont.woff") format("woff"), url("../font/chevinstd-light-webfont.ttf") format("truetype"), url("../font/chevinstd-light-webfont.svg#Chevin") format("svg");
}
.chevin_light { font-family:'Chevin-Light',Arial,Helvetica,sans-serif; font-size:32px; }
2 Answers
ryankite
8,265 PointsTry this out.
@font-face {
font-family: 'Chevin-Light';
src: url('../font/chevinstd-light-webfont.eot');
src: url('../font/chevinstd-light-webfont.eot') format ('embedded-opentype'),
url('../font/chevinstd-light-webfont.woff') format ('woff'),
url('../font/chevinstd-light-webfont.ttf') format ('truetype'),
url('../font/chevinstd-light-webfont.svg#Chevin') format ('svg');
}
.chevin_light {
font-family:'Chevin-Light',Arial,Helvetica,sans-serif;
font-size:32px;
}
jdh
12,334 PointsThanks, Ryan. I think the issue in the end was that I have the link tags for my CSS styling before my bootstrap link.