Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #858324

    speester
    Participant

    I tired adding to

    customizer > Custom > css

    @import url(https://fonts.googleapis.com/css?family=Stalemate);

    Customizer > custom > Java

    <script type=”text/javascript”>
    WebFontConfig = {
    google: { families: [ ‘Stalemate::latin’ ] }
    };
    (function() {
    var wf = document.createElement(‘script’);
    wf.src = ‘https://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>

    In corner stone, i add

    <span style=”font-size: 24px; font-family: ‘quicksand'”>text content</span>

    it works

    But when i add

    <span style=”font-size: 24px; font-family: ‘Stalemate’, cursive;'”>text content</span>

    It does not work.

    #858326

    speester
    Participant
    This reply has been marked as private.
    #858391

    Lely
    Moderator

    Hi Nelson,

    Please note that <script> tag is not needed on Customizer > Javascript. Please update the code to this:

      WebFontConfig = {
        google: { families: [ 'Allura::latin' ] }
      };
      (function() {
        var wf = document.createElement('script');
        wf.src = 'https://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);
      })(); 

    For Stalemate, you don’t need to enclose it with the single quote like below:
    <span style="font-size: 24px; font-family: Stalemate, cursive;">text content</span>
    See attached image.

    Hope this helps.

    #858729

    speester
    Participant

    WebFontConfig = {
    google: { families: [ ‘Allura::latin’ ] }
    };
    (function() {
    var wf = document.createElement(‘script’);
    wf.src = ‘https://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);
    })();

    ====================================

    I changed to the code you provided above.

    I tried both the

    text block method
    <span style=”font-size: 24px; font-family: Stalemate, cursive;”>text content</span>

    Custom headline method
    adding font-family: Stalemate to style

    ======================================

    Still does not work.

    #858968

    Rupok
    Member

    Hi there,

    Thanks for updating. I can’t see the script on your Customizer – http://prntscr.com/am2stv

    Would you clarify where you have added to load the font?

    Cheers!