Create a multi-language store in Magento 2 – Part 2
In the first post from this series, we’ve focused more on theory and technical background behind multi-language Magento2 store. Now, we’ll create Magento2 store with additional French language. First thing is to go to the administration and create a new store view. Before we proceed, please check documentation where is explained a difference between store view, store and website, old but still relevant, http://docs.magento.com/m1/ce/user_guide/store-operations/stores-multiple.html.
Inside Magento 2 admin go to Stores – Configuration – All store and please follow steps bellow and create new store view.
You need to populate some basic info about store.
After Save we will have 2 store views named English (Default store) and new one French store.
Next go to Stores – Configuration, and now please pay attention on store “scopes”, store view needs to match to language which you want to edit.
Now change to desired Country, French, Belgium maybe.
Next important thing is Locale, here you need to select which language store will speak, based on that we will install language pack.
So right now we will have store switch on frontend.
So, the next thing is to install the language pack. I will use the one downloaded from github. Now, there’s 2 most common installation approach. First one is to use a composer. That is recommended, because in feature it will have updated terms with newer version of Magento, but I prefer to download and install manually language pack for most obvious reason – one language pack will not cover all phrases and you will need to manually add some or change current one. So I will manually install French language pack :-).
After you have downloaded language pack, copy it inside Magento app directory, create a new folder i18n, Create Folder named upon vendor, and lastly create folder using store language codes, in our case it’s FR_fr.
So, the path will look like this:
After we have copied files next step is to flush Magento cache.
Now on frontend switch to French language store and there will be translated common terms like welcome, log in, register, search newsletter etc. Please note this is Magento with sample data, you need to translate static blocks in order to have all content translated to french language. Also there is an option to create a different homepage and add different content for each store view.
I hope that this short “walktrough” is enough for starting to expand business and engage customers on different languages with Magento2.
https://marketplace.magento.com/inchoo-language-hr-hr.html this is only for Croatian language ,
If need to set different language for different store view , then functionality need to add in this module please explain.
What about URLs? Can we update url as per language?? I mean store view wise??
Can You Provide Language Pack Github Link If Possible?
Hi, try with this one https://marketplace.magento.com/inchoo-language-hr-hr.html
Previously I’ve also created store views for different languages, but I’ve found that it takes longer for switching from developer mode back to production the more languages I add. Magento seems to have compiled the different languages for the backend and the Luma theme too which I don’t use at all. Is it possible to exclude these somehow when changing between the modes?