Viewing 19 posts - 1 through 19 (of 19 total)
  • Author
    Posts
  • #1021317

    Hello,

    I had to use a specific font for my website headers called ‘KG All of Me’ so I use a plugin that was recommended on some of the forums called ‘Use any font’. The host I’m using is a multi-site so I figured this would be the easiest way to do it.

    I installed the plugin and uploaded the .ttf font and then added the css in to the admin section in Enfold:

    h1, h2, h3, h4, h5, h6, .menu-item a {
    font-family: KGAllofMe!important;
    }

    The font now works great on the desktop now but I just checked on the mobile and it is defaulting to a font which looks nothing like KG All of me.
    I am hoping you know an easy way to fix this for me?

    Thank you
    Joe

    #1021403

    Hey Joe,

    The font is not loading at all on my end, did you install the font locally on your machine? If so it might be working on your local machine since it’s installed there. Did you make sure that the name of the font is correct in your CSS? Also, did you try to import it using CSS rather than using a plugin?

    Best regards,
    Rikard

    #1021695

    Hi Rikard,
    I downloaded the font on to my machine as a ttf then uploaded it from my desktop via the plugin in the wordpress admin section. I copied and pasted the css along with the font name so I assume it was done correctly as it worked ok after I’d done this but if it’ not working your end or on my phone then it must be working locally and thats not what I’m after.

    What is the correct way to do this using css? I can delete the plugin and css I used and try again using a different method if you know a better way?

    Thanks
    Joe

    #1021961

    Hi Joe,

    Ok, thanks for the feedback. Maybe the plugin you are using is not working, could you try importing the font manually using CSS maybe? You can find instructions on how to do it here: https://www.w3schools.com/css/css3_fonts.asp

    Best regards,
    Rikard

    #1022187

    Thanks Rikard,

    Ok, so I’ve deleted the plugin and css and started again but I can’t get it to work, maybe you can check what I’ve done and let me know what I might have done wrong?

    I converted the kgallofme.ttf font with font squirrel and this created woff and woff2 files so I uploaded these to a ‘fonts’ folded in a child theme on my main site (link below). I then added the following code to the top of the Quick css box in the enfold general styling section.

    @font-face {
    font-family: ‘kgallofme-webfont’;
    src: url(‘https://gettopageone.com/wp-content/themes/enfold-child/fonts/kgallofme-webfont.woff2’) format(‘woff2’),
    url(‘https://gettopageone.com/wp-content/themes/enfold-child/fonts/kgallofme-webfont.woff’) format(‘woff’);
    font-weight: normal;
    font-style: normal;
    }

    h1, h2, h3, h4, h5, h6, .menu-item a {
    font-family: kgallofme-webfont.ttf!important;
    }

    Hopefully this is somewhere close and an easy fix?
    Thank you.

    #1022518

    Hi,

    1. This URL leads to a 404 page, please check it: https://gettopageone.com/wp-content/themes/enfold-child/fonts/kgallofme-webfont.woff2

    2. The font family is the same as this: font-family: ‘kgallofme-webfont’;. Remove the file ending in your code.

    Best regards,
    Rikard

    #1022668

    Thanks Rikard,
    I have moved the fonts and the URL to the font seems ok now and I’ve changed my css to this however the font still doesn’t see to load on the webpage. Any ideas? Thanks.

    @font-face {
    font-family: ‘kgallofme-webfont’;
    src: url(‘http://engageyourbrand.co.uk/wp-content/themes/enfold-child/fonts/kgallofme-webfont.woff2’) format(‘woff2’),
    url(‘http://engageyourbrand.co.uk/wp-content/themes/enfold-child/fonts/kgallofme-webfont.woff’) format(‘woff’);
    font-weight: normal;
    font-style: normal;
    }

    h1, h2, h3, h4, h5, h6, .menu-item a {
    font-family: kgallofme-webfont;
    }

    #1023119

    Hi,

    Thanks for that. Everything seems to be correct and I can see your CSS applying, though your SSL certificate seems to be the problem now. I haven’t seen this happen before so I’m not really sure how to fix it. Maybe this will help? https://www.drivereasy.com/knowledge/fix-err-cert-common-name-invalid-chrome-solved/

    Best regards,
    Rikard

    #1023241

    Hi Rikard,
    Thanks for that information, it’s really helpful.
    The sites will eventually have SSL certificates so I will wait until then to see if the font applies.
    Thanks for your help.
    Joe

    #1023350

    Hello again, actually please could you check this again?
    The web site here is now live and secure.
    The css is below and link to the font is on a secure site.
    Everything seems ok now but the font still doesn’t work? Any other ideas?
    Thanks

    @font-face {
    font-family: ‘kgallofme-webfont’;
    src: url(‘https://gettopageone.com/wp-content/themes/enfold-child/kgallofme-webfont.woff2’) format(‘woff2’),
    url(‘https://gettopageone.com/wp-content/themes/enfold-child/kgallofme-webfont.woff’) format(‘woff’);
    font-weight: normal;
    font-style: normal;
    }

    h1, h2, h3, h4, h5, h6, .menu-item a {
    font-family: kgallofme-webfont;
    }

    #1024049

    Hi,

    Where did you add the css code? The headings are still using the theme font, currently set to “Lato”.

    h1, h2, h3, h4, h5, h6, #top .title_container .main-title, tr.pricing-row td, #top .portfolio-title, .callout .content-area, .avia-big-box .avia-innerbox, .av-special-font, .av-current-sort-title, .html_elegant-blog #top .minor-meta, #av-burger-menu-ul li {
        font-family: 'Lato', 'HelveticaNeue', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    }
    

    Best regards,
    Ismael

    #1024163

    Hi Ismael,
    Thanks for getting back to me, that’s interesting. The css code is pasted in to the Quick css box in the admin section of Enfold.
    Do you think the css below is wrong or not applying?
    @font-face {
    font-family: ‘kgallofme-webfont’;
    src: url(‘https://gettopageone.com/wp-content/themes/enfold-child/kgallofme-webfont.woff2’) format(‘woff2’),
    url(‘https://gettopageone.com/wp-content/themes/enfold-child/kgallofme-webfont.woff’) format(‘woff’);
    font-weight: normal;
    font-style: normal;
    }

    h1, h2, h3, h4, h5, h6, .menu-item a {
    font-family: kgallofme-webfont;
    }

    Thanks
    Joe

    #1024656

    Hi,

    Why do you access the font from another site? It’s causing a cross origin issue. (see private field)

    This might help: https://kriesi.at/documentation/enfold/icon/#icons-are-showing-as-rectangular-boxes-

    Or just upload the font to the “sportsbarnorthernquarter” site.

    Best regards,
    Ismael

    #1025530

    Hi Ismael,

    Thanks a lot for this, as it’s set up on a multi-site the easiest option was for me to change the .htaccess file and the header fonts all seem to work as I’d like now.

    One last thing, the menu fonts for Home | About | Services | Contact are still in the wrong font. Is this because the code below is wrong?

    h1, h2, h3, h4, h5, h6, .menu-item a {
    font-family: kgallofme-webfont;
    }

    Thanks for your help.
    Joe

    #1025746

    Hi,

    Thanks for the update. Try this css code for the main menu.

    #top .header_color .main_menu ul> li > a {
         font-family: kgallofme-webfont;
    }

    Best regards,
    Ismael

    #1025842

    Hi Ismael,
    I cut and pasted the code in to the top of the css box but it didn’t seem to work.
    I added it on to this website:

    I would also like to change the body copy to be the KG font also.
    Thanks
    Joe

    #1025918

    Hi,

    The font is set to “Special Elite”. Please remove this css code.

    #top #header .av-main-nav > li {
        font-family: Special Elite;
    }

    And upgrade the theme to version 4.5.

    Best regards,
    Ismael

    #1025961

    Thanks for your Ismael, all is working now.
    Much appreciated!

    #1026348

    Hi,

    Great! Glad we could help!

    Please take a moment to review our theme and show your support https://themeforest.net/downloads
    Don’t forget to bookmark Enfold Documentation for future reference.

    Thank you for using Enfold :)

    Best regards,
    Ismael

Viewing 19 posts - 1 through 19 (of 19 total)
  • The topic ‘use-any-font.5.0’ is closed to new replies.