Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1128956
    pjayd
    Participant

    Hi there – I’m trying to upload two custom fonts to use with my X theme.

    I’ve tried following the directions in both of these threads but am not having any luck:
    https://community.theme.co/forums/topic/custom-font-2/
    https://community.theme.co/forums/topic/adding-custom-font-to-theme-customizer/

    My URL is weddings.elviramaryvideographers.com. I uploaded the files to the FontFace generator, uploaded them to the root directory, and added the CSS in the custom CSS space in Customizer but it’s still not working.

    Any suggestions?

    Thanks!

    #1129261
    Friech
    Moderator

    Hi There,

    Thanks for writing in! Please follow the guide provided here: https://community.theme.co/forums/topic/menu-font-changes/page/2/#post-881256

    Hope it helps, Cheers!

    #1130985
    pjayd
    Participant
    This reply has been marked as private.
    #1131221
    Rue Nel
    Moderator

    Hello There,

    Thanks for the updates! it is not working because you were using a relative path. Please use a direct path instead. You can make make use of this code format:

    @font-face {
        font-family: 'Shorelines';
        src:url('http://www.weddings.elviramaryvideographers.com/wp-content/themes/x-child/framework/fonts/Shorelines/shorelines_script_bold-webfont.woff') format('woff'),
            url('http://www.weddings.elviramaryvideographers.com/wp-content/themes/x-child/framework/fonts/Shorelines/shorelines_script_bold-webfont.svg#shorelines_script_bold-webfont') format('svg'),
            url('http://www.weddings.elviramaryvideographers.com/wp-content/themes/x-child/framework/fonts/Shorelines/shorelines_script_bold-webfont.eot'),
            url('http://www.weddings.elviramaryvideographers.com/wp-content/themes/x-child/framework/fonts/Shorelines/shorelines_script_bold-webfont.ttf') format('truetype'),
            url('http://www.weddings.elviramaryvideographers.com/wp-content/themes/x-child/framework/fonts/Shorelines/shorelines_script_bold-webfont.eot?#iefix') format('embedded-opentype');
    }
    
    header .x-brand.text {
        font-family: 'Shorelines', sans-serif !important;
    }

    You must declare the font first before you can use it in styling the other elements on the page.

    Hope this helps. Please let us know how it goes.

    #1132135
    pjayd
    Participant

    Thanks so much!!! I still had to enter font-family: ‘Shorelines’, sans-serif !important; in the style of the individual headers but it’s working now!

    #1132154
    Jade
    Moderator

    You’re most welcome.

    #1132224
    pjayd
    Participant

    Hi Jade – I actually have one more question… I’m just doing final tests on my site to make sure everything looks good and I’ve noticed a few tiny problems on mobile. The main issue is that my topbar doesn’t look the same. On desktop, it’s a pink background with white link text that hovers grey (http://www.weddings.elviramaryvideographers.com/)

    The problem is that on mobile there seems to be another container of white background within the topbar. See attached.

    How can I fix that?

    Thanks!

    #1132234
    pjayd
    Participant

    One last thing – my custom fonts don’t seem to always work on mobile.

    #1132274
    Joao
    Moderator

    Hi There,

    Would you mind cleaning your mobile browser cache and testing it again?

    It is unlikely that the fonts won´t load specifically on mobile.

    Let us know how it goes,

    Joao

    #1132420
    pjayd
    Participant

    Hi Joao,

    I just cleared the browser and it’s still not working on mobile. Would this be a problem with x theme vs child theme? I think this font is in the x-theme framework -> fonts folders.

    also – do you have any idea about my question before that? about why the topbar isn’t showing up right on mobile?

    Thanks

    #1132649
    Jade
    Moderator

    Hi there,

    Please add this code in the customizer to fix the topbar:

    .x-topbar .p-info {
        background-color: transparent;
    }

    I have just checked your site on my mobile and the fonts seem to be displaying correctly. It’s probably a cache issue. Try to load the site in private browsing mode or incognito mode.

  • <script> jQuery(function($){ $("#no-reply-1128956 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>