Time for action—installing a new language pack

In this section, we will learn how to install a new language pack in OpenCart. For our example, we will use Swedish.

  1. Let's browse into http://www.opencart.com/ and click on the Extensions menu. Let's search the keyword swedish in the Languages section and then click on the Filter button:
    Time for action—installing a new language pack
  2. We have found a Swedish Capitalize to fit with screenshot language pack. Let's browse into the Download tab and save the file in our computer by clicking on the Download button:
    Time for action—installing a new language pack
  3. Let's extract the contents of the swedish.zip file to the same folder on our computer:
    Time for action—installing a new language pack
  4. As we can see from the following screenshot, we have now two folders extracted; admin and catalog:
    Time for action—installing a new language pack
  5. Let's enter into the admin folder. We will notice a folder named swedish. Let's compress it as swedish.zip:
    Time for action—installing a new language pack
  6. We will do the same thing in the catalog folder. Let's compress the swedish folder as swedish.zip there:
    Time for action—installing a new language pack
  7. Let's open File Manager in cPanel which our hosting solution has provided for us:

    Note

    Alternatively, we could use a free ftp client to upload the files. Filezilla is just one of them, freely available on http://filezilla-project.org/

    Time for action—installing a new language pack
  8. Let's first open the path admin/language in our OpenCart installation. We will see the already installed english folder. Let's click on the Upload button now:
    Time for action—installing a new language pack
  9. We should upload the swedish.zip file which is found in the admin folder to the admin/language folder on the server. Be careful to upload the correct swedish.zip file. After this, let's extract the contents of the swedish.zip file here by clicking on the Extract button:
    Time for action—installing a new language pack
  10. We will do the same thing for the catalog/language folder on the server. Open this server path and click on the Upload button:
    Time for action—installing a new language pack
  11. We will upload the swedish.zip file from the local catalog folder to the catalog/language path on the server. After uploading, choose the swedish.zip file, and click on the Extract button to extract the contents here:
    Time for action—installing a new language pack
  12. Let's log in to the administration panel. We will open the System | Localisation | Languages menu:
    Time for action—installing a new language pack
  13. We already have English installed there by default. Let's click on the Insert button:
    Time for action—installing a new language pack
  14. We will need to fill in Swedish language information as shown in the following screenshot. You can copy and paste the following field values. Finally, do not forget to select the Status option as Enabled and Save.

    Note

    The following information about Swedish can be found in the readme file in the archive file we had downloaded. Most language packs include such settings in a readme file as well.

    Locale: sv_SE.UTF-8,sv_SE,swedish

    Image: se.png

    Time for action—installing a new language pack
  15. Let's browse into the store front and select language option as Swedish:
    Time for action—installing a new language pack
  16. As we can see from the following screenshot, the store now operates in Swedish. All menu items and other definitions are changed to Swedish. Store visitors can do this at any time they want on the store front.
    Time for action—installing a new language pack
  17. Additionally, we can arrange default local language settings in the System | Settings | Local menu in administration panel.
    Time for action—installing a new language pack

What just happened?

We have just learned where to look for different language packs for OpenCart. We have downloaded a language pack. We have separately arranged language files for admin and catalog folders. We have then uploaded them to their respective folders on the server. Finally, we have inserted the new language definition on administration panel.

Have a go hero—in running the store on your own language

Now, it is your turn to repeat these steps for your selected language. If you can't find an available language pack for your language, you can still write your own translations by editing language files on the server.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.116.21.239