Archived topic
Different font for each language
7 replies · Started by Roy on October 1, 2017
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
Hi Roy,
Which element are you applying it to? The body?
Hi Tom,
Thanks for the quick reply.
I would like to apply it for the body, all headings, navigation menus and widgets.
Thanks
Hmm, ok.
Can you link me to a page in each language possibly?
Thanks!
English:
http://gilad.rbwise.com/services/
Hebrew:
http://gilad.rbwise.com/he/%D7%A9%D7%99%D7%A8%D7%95%D7%AA%D7%99%D7%9D/
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 :)
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).
You should just be able to add the Arabic version like the English version: https://docs.generatepress.com/article/adding-local-fonts/