Tagged: 

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #29683

    hy,

    i load the font for diactritic in header before head:

    <link href=’http://fonts.googleapis.com/css?family=Open+Sans:600,400&subset=latin,latin-ext&#8217; rel=’stylesheet’ type=’text/css’>

    i use open sans for font, in safari and chrome is loading ok, but in fireox not

    is something from firefox? or my solution is not ok for loading font with diactritics?

    thank you

    #141263

    Hey,

    Can you give us a link to your website?

    Edit header.php, find this code:

    <?php
    
    if( strpos($responsive, 'responsive') !== false ) echo '<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">';
    
    ?>

    Below, add this:

    <script type="text/javascript">
      WebFontConfig = {
        google: { families: [ 'Open+Sans::cyrillic-ext,latin,greek-ext,greek,vietnamese,latin-ext,cyrillic' ] }
      };
      (function() {
        var wf = document.createElement('script');
        wf.src = ('https:' == document.location.protocol ? 'https' : 'http') +
          '://ajax.googleapis.com/ajax/libs/webfont/1/webfont.js';
        wf.type = 'text/javascript';
        wf.async = 'true';
        var s = document.getElementsByTagName('script')[0];
        s.parentNode.insertBefore(wf, s);
      })(); 
    </script>

    Regards,
    Ismael

    #161503

    This setting is worse, not working properly in any browser, with first code only in firefox.
    example

    Currently, is only local to translate, in a few days can give you the link if there is need.

    #162633

    ok. works, but with this.

    <script type="text/javascript">
      WebFontConfig = {
        google: { families: [ 'Open+Sans:400,600:latin,latin-ext' ] }
      };
      (function() {
        var wf = document.createElement('script');
        wf.src = ('https:' == document.location.protocol ? 'https' : 'http') +
          '://ajax.googleapis.com/ajax/libs/webfont/1/webfont.js';
        wf.type = 'text/javascript';
        wf.async = 'true';
        var s = document.getElementsByTagName('script')[0];
        s.parentNode.insertBefore(wf, s);
      })(); </script>
    

    thanks

Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘how to load font with diactritics?’ is closed to new replies.