[Support request] Different font for each language

Home Forums Support [Support request] Different font for each language

Home Forums Support Different font for each language

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #395408
    Roy

    Hi,
    I use Polylang for creating a multi language website (in Hebrew and English).

    Is there an option to set that the font for hebrew will be “Arimo” and for english it will be “Open Sans”? The Customizer allows to set only one language.

    Thanks,
    Roy

    #395602
    Tom
    Lead Developer
    Lead Developer

    Hi Roy,

    Which element are you applying it to? The body?

    #395677
    Roy

    Hi Tom,
    Thanks for the quick reply.

    I would like to apply it for the body, all headings, navigation menus and widgets.

    Thanks

    #395943
    Tom
    Lead Developer
    Lead Developer

    Hmm, ok.

    Can you link me to a page in each language possibly?

    #395961
    Roy
    #396252
    Tom
    Lead Developer
    Lead Developer

    Try adding this CSS:

    html[lang="he-IL"] body {
        font-family: Arimo;
    }

    Then this function:

    add_filter( 'generate_typography_google_fonts', 'tu_add_extra_fonts' );
    function tu_add_extra_fonts( $google_fonts ) {
        return $google_fonts . '|Arimo';
    }

    Let me know if this helps or not 🙂

    #877147
    Kyro Peregrin

    Thanks I need this, My question is how about I already upload the custom font of my website.

    I already manage to use the custom font in english but now i want to call the font in arabic (DRIOD ARABIC KUFI).

    #877693
    Tom
    Lead Developer
    Lead Developer

    You should just be able to add the Arabic version like the English version: https://docs.generatepress.com/article/adding-local-fonts/

Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.