Jump to content

Change font type for each language


monaliali

Recommended Posts

Hi every one;

I use Prestashop 1.6

I use two languages English and Arabic.

I want to change the font type of the Arabic language because  the default font type is not attractive and it seems small.

Just for the Arabic language. For the English language, it's ok and I dont want to change it.

Thank you

Edited by monaliali (see edit history)
Link to comment
Share on other sites

Hi every one;

I use Prestashop 1.6

I use two languages English and Arabic.

I want to change the font type of the Arabic language because  the default font type is not attractive and it seems small.

Just for the Arabic language. For the English language, it's ok and I dont want to change it.

Thank you

 

You have to edit css file for your theme and overwrite font-family property. For example, on standard 1.6 bootstrap theme, you could add

 
html[lang="cs-cz"], html[lang="cs-cz"] body, html[lang="cs-cz"] h1 {
  font-family: courier;
}

to /themes/default-bootstrap/css/global.css, which will change font for czech language to courier. For your theme it might, and it probably will, differ. 

  • Like 1
Link to comment
Share on other sites

Thank you my friend for your reply. I try what you mentioned but it doesn't work  :(

I added the font to the "fonts.css" file and I uploaded it to the 'Fonts" directory with 'OTF' extension

and I added the code you sent to me ( after changing the lang to "ar" and the font-family to the font I uploaded)

Nothing happen

Link to comment
Share on other sites

Well, it really depends on theme you are using. My example works for standard theme.

 

If you use standard theme, then

 

1. verify your <html> tag contains lang attribute - look at page source

 

 

vaQNEXAVXi4x86bOJfcvHt7Vg4DjuD.png

 

2. make sure your lang selector in css matches exactly value of lang attribute - it's case sensitive

3. clear cache in your prestashop

4. clear cache in your browser

 

And it should work

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...