How to use translation files

To use a translation, you must have both the .po and .mo files of a language.

.po files can be downloaded from the project page on Transifex.

Once you have them, you must place each one on the corresponding folder:

  • Back end text strings – /lang
  • Template: Default – /templates/default/lang
  • Template: Gallery – /templates/gallery/lang
  • Template: Pinboxes – /templates/pinboxes/lang

If you don’t have the .mo file (the compiled version of the .po), you need to download the small but awesome software Poedit.

With Poedit you can open the .po files. As soon as you save, the .mo file is generated automatically on the same folder as the original .po.

poedit-example

Example of poedit with the spanish file open (es.po)


Now that you have every .mo file generated, you need to tell ProjectSend to use it.

To do it, open the file /includes/sys.config.php with a text editor of your choice.

There, find the line that reads something like this:

define(‘SITE_LANG’,’en’);

And change the value to the name of the file of your language minus the file extension.

For example, if you want to use the French language, change it to

define(‘SITE_LANG’,’fr’);

If your language is localized, like in the case of Portuguese (which has the Brazil and Portugal variations), be sure to include the full name. For example, for Portuguese (Brazil), use

┬ádefine(‘SITE_LANG’,’pt_BR’);


 

That’s it! The next page you load should be in your new language.


Top