Click here to Skip to main content
15,886,362 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi guys,

I've been trying to load a hosted font (for all clients but Outlook) into my email template but it does not seem to work.

What I have tried:

HTML
<style type="text/css" >
   @media screen{
      @font-face{
         font-family: 'Archive';
         font-style: normal;
         font-weight: normal;           	    
         src:url(https://[DOMAIN NAME]/templates/ettu/assets/fonts/Archive.ttf.woff) format('woff');
       }
   }
</style>


I've tried different variants of the above code and loading the style like this:

HTML
<p style="font-family: 'Archive', Arial, sans-serif;">TEXT HERE</p>


I can't find out what i'm doing wrong but it doesn't work. Any suggestions would be greatly appreciated. Thanks in advance!
Posted
Updated 22-Jan-18 4:07am
v2
Comments
F-ES Sitecore 22-Jan-18 9:35am    
You're unlikely to get this working as mail clients are reluctant to download external resources unless the user has allowed it. You could change the url to

src:url(https://[DOMAIN NAME]/templates/ettu/assets/fonts/Archive.ttf.woff?email=this@persons.address.com)

and that would allow you to start tracking that user, to determine if they opened the email etc.
Member 13637011 22-Jan-18 9:44am    
@fes-sitecore So this means this will not work like web fonts? That's too bad! Thanks for your time and your answer!

1 solution

Some Email systems do allow for web fonts by embedding the font directly in the HTML: The Ultimate Guide to Web Fonts in Email—Litmus Software, Inc.[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900