I have a non-standard font file in .eot format and use the following CSS syntax to embed it into the master page:

@font-face
{
    font-family: Myfontfamily;
    src: url("http://server/_layouts/STYLES/Fonts/myfont.eot") format("embedded-opentype");
}

.customfont
{
    font-family: Myfontfamily;  
}

On my master page I have the following HTML:

<p class="customfont">Some random text</p>

It works fine, when used in a plain ASP.NET site (within the same IIS instance), but not in SharePoint. Custom font is not applied on the SharePoint master page. Do I need to make any additional actions for SharePoint? I also need this non-standard font to appear in the Content Editor web part, is it possible? Thx.

link|improve this question

0% accept rate
feedback

1 Answer

I'm not sure, but could you change you're URL to point to relative path? In other words try to change your url to something like ("/_layout/STYLES/fonyts/myfont.eot")

link|improve this answer
you should also register your css files (csslink/cssregistration) within your file.master – SunChero Jan 10 at 15:21
How can i use sansa fonts. Will it work with sharepoint?Does microsoft support it? Cheers – naijacoder Jan 11 at 6:19
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.