1. <?php
  2.  
  3. /**
  4. * Load Josefin Sans typeface
  5. */
  6. if ( ! function_exists( 'blaskan_font_face' ) ):
  7. function blaskan_font_face() {
  8. if ( BLASKAN_TYPEFACE_TITLE == 'default' ) {
  9. echo "
  10. <style type='text/css'>
  11. /**
  12. * Bulletproof syntax:
  13. * http://www.fontspring.com/blog/further-hardening-of-the-bulletproof-syntax
  14. * Font files generated by Font Squirrel:
  15. * http://www.fontsquirrel.com
  16. * License: Open Font License. See " . get_template_directory_uri() . "/OFL.txt.
  17. */
  18. @font-face {
  19. font-family: 'JosefinSansStdLight';
  20. src: url('" . get_template_directory_uri() . "/fonts/JosefinSansStd-Light-webfont.eot'); /* IE9 Compat Modes */
  21. src: url('" . get_template_directory_uri() . "/fonts/JosefinSansStd-Light-webfont.eot?#iefix') format('eot'), /* IE6-IE8 */
  22. url('" . get_template_directory_uri() . "/fonts/JosefinSansStd-Light-webfont.woff') format('woff'), /* Modern Browsers */
  23. url('" . get_template_directory_uri() . "/fonts/JosefinSansStd-Light-webfont.ttf') format('truetype'), /* Safari, Android, iOS */
  24. url('" . get_template_directory_uri() . "/fonts/JosefinSansStd-Light-webfont.svg#JosefinSansStdLight') format('svg'); /* Legacy iOS */
  25. }
  26. </style>
  27. ";
  28. }
  29. }
  30. endif;
  31. add_action( 'wp_head', 'blaskan_font_face', 1 );
  32.  
  33. /**
  34. * Load Lora typeface
  35. */
  36. if ( ! function_exists( 'blaskan_font_face' ) ):
  37. function blaskan_font_face() {
  38. if ( BLASKAN_TYPEFACE_TITLE == 'default' ) {
  39. echo "
  40. <style type='text/css'>
  41. /**
  42. * Bulletproof syntax:
  43. * http://www.fontspring.com/blog/further-hardening-of-the-bulletproof-syntax
  44. * Font files generated by Font Squirrel:
  45. * http://www.fontsquirrel.com
  46. * License: Open Font License. See " . get_template_directory_uri() . "/OFL.txt.
  47. */
  48. @font-face {
  49. font-family: 'LoraRegular';
  50. src: url('" . get_template_directory_uri() . "/fonts/Lora-Regular-webfont.eot'); /* IE9 Compat Modes */
  51. src: url('" . get_template_directory_uri() . "/fonts/Lora-Regular-webfont.eot?#iefix') format('eot'), /* IE6-IE8 */
  52. url('" . get_template_directory_uri() . "/fonts/Lora-Regular-webfont.woff') format('woff'), /* Modern Browsers */
  53. url('" . get_template_directory_uri() . "/fonts/Lora-Regular-webfont.ttf') format('truetype'), /* Safari, Android, iOS */
  54. url('" . get_template_directory_uri() . "/fonts/Lora-Regular-webfont.svg#LoraRegular') format('svg'); /* Legacy iOS */
  55. }
  56. </style>
  57. ";
  58. }
  59. }
  60. endif;
  61. add_action( 'wp_head', 'blaskan_font_face', 1 );
  62. ?>