Posted By

ertbor on 02/05/11


Tagged

css typography


Versions (?)

Who likes this?

1 person have marked this snippet as a favorite

wirenaught


Bulletproof @Font-Face Syntax


 / Published in: CSS
 

URL: http://www.fontspring.com/blog/the-new-bulletproof-font-face-syntax

The find and replace regular expressions convert from Font Squirrel's generated @font-face.

  1. Find:
  2. src: url\('(.*?)'\);
  3. src: local\('☺'\), url\('(.*?)'\) format\('woff'\), url\('(.*?)'\) format\('truetype'\), url\('(.*?)'\) format\('svg'\);
  4.  
  5. Replace:
  6. src: url('$1#') format('embedded-opentype'),
  7. url('$2') format('woff'),
  8. url('$3') format('truetype'),
  9. url('$4') format('svg') ;

Report this snippet  

You need to login to post a comment.