Problem translation .po files
Forum rules
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Problem translation .po files
Hello everybody, from Ukraine! Firstly I want to say thank to aimeos developers for this nice package. I really like it. Well, I have a problem: I want to translate aimeos, but I can't do it. As I understand aimeos use online translation. But I want to you use .po files and translate it. I see .po files in project/ext/ai-admin-jqadm/admin/i18n. So I want to translate, for example, admin panel.
I add to ru.po file this:
msgid "Latest orders"
msgstr "my text"
But it not working. I saw the same topics on this site, but I not found answer for my question.
I hope for yours help very much.
Great thank!
I add to ru.po file this:
msgid "Latest orders"
msgstr "my text"
But it not working. I saw the same topics on this site, but I not found answer for my question.
I hope for yours help very much.
Great thank!
Re: Problem translation .po files
Sorry I forgot say: I use php7, laravel 5.3.28, windows 7
Re: Problem translation .po files
Excuse me, "aimeos/aimeos-core": "~2016.10" it is version of aimeos which I use
Re: Problem translation .po files
Dear Users!) I understand how it work:
'i18n' => array(
'en' => array(
'admin' => array(
'Latest orders' => array('my text'),
),
),
),
and it really work! But I think it is bad way to translate all aimeos package. I want it. I need translate using .po files. I think it will be more comfortable. I can't understand why aimeos do not use .po files and why this files exits consequently)
'i18n' => array(
'en' => array(
'admin' => array(
'Latest orders' => array('my text'),
),
),
),
and it really work! But I think it is bad way to translate all aimeos package. I want it. I need translate using .po files. I think it will be more comfortable. I can't understand why aimeos do not use .po files and why this files exits consequently)
Re: Problem translation .po files
Here are the options you have:
- To contribute to the official translation, you have to use Transifex
- To overwrite a few strings locally, you can use the configuration as you've mentioned
- If you want to replace more strings with your own translations and your translations are specific to your project, create your own po/mo files
The steps for the last options are:
- Create an extension for your project
- Copy the existing .po file (ru.po) to the same directory structure as in the core extensions
- Change the translations you want to replace
- Remove the strings/translations that should stay the same
- Execute in the directory of the .po file: "msgfmt --statistics -c -o ru ru.po"
This creates the binary mo file (ru) which is used when translations for Russian are requested. If no translation in this available, the translation from the core mo file is used.
- To contribute to the official translation, you have to use Transifex
- To overwrite a few strings locally, you can use the configuration as you've mentioned
- If you want to replace more strings with your own translations and your translations are specific to your project, create your own po/mo files
The steps for the last options are:
- Create an extension for your project
- Copy the existing .po file (ru.po) to the same directory structure as in the core extensions
- Change the translations you want to replace
- Remove the strings/translations that should stay the same
- Execute in the directory of the .po file: "msgfmt --statistics -c -o ru ru.po"
This creates the binary mo file (ru) which is used when translations for Russian are requested. If no translation in this available, the translation from the core mo file is used.
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos,
give us a star
If you like Aimeos,

Re: Problem translation .po files
aimeos, thank you very much! Excuse me, I want to clarify something.
1. Where I can get documentation how create aimeos extension for translating ?
2. You say that I must to Copy the existing .po file (ru.po) to the same directory structure as in the core extensions. But in folder myproject/ext/ I see many derictories which contein .po files.
So tell me please how extension structure must be look, and how I must say to aimeos to use this .po files in my extension.
I execute "php msgfmt --statistics -c -o ru ru.po" in myproject\vendor\aimeos\aimeos-core\ext\aomeos-ru-translater\admin\i18n and I see Could not open input file: msgfmt
https://aimeos.org/developer/extensions/ - I create and download archive, help me please, where I have to unzip this, and what I must to do after this
Thank you! You are really help me.
1. Where I can get documentation how create aimeos extension for translating ?
2. You say that I must to Copy the existing .po file (ru.po) to the same directory structure as in the core extensions. But in folder myproject/ext/ I see many derictories which contein .po files.
So tell me please how extension structure must be look, and how I must say to aimeos to use this .po files in my extension.
I execute "php msgfmt --statistics -c -o ru ru.po" in myproject\vendor\aimeos\aimeos-core\ext\aomeos-ru-translater\admin\i18n and I see Could not open input file: msgfmt
https://aimeos.org/developer/extensions/ - I create and download archive, help me please, where I have to unzip this, and what I must to do after this
Thank you! You are really help me.
Re: Problem translation .po files
This article should answer your questions:
https://aimeos.org/docs/Developers/Create_an_extension
Copy the existing ru.po file to the same directory in your own extension, e.g. from "./ext/ai-client-html/client/i18n/ru.po" to "./ext/myextname/client/i18n/ru.po".
"msgfmt" is a Unix CLI command. To use it in a Windows environment, you have to install Cygwin and its gettext package first.
https://aimeos.org/docs/Developers/Create_an_extension
Copy the existing ru.po file to the same directory in your own extension, e.g. from "./ext/ai-client-html/client/i18n/ru.po" to "./ext/myextname/client/i18n/ru.po".
"msgfmt" is a Unix CLI command. To use it in a Windows environment, you have to install Cygwin and its gettext package first.
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos,
give us a star
If you like Aimeos,

Re: Problem translation .po files
aimeos, I yet have some problems. I install Cygwin, but in windows cmd console I see Could not open input file: msgfmt, and in Cygwin console I see "Could not open input file: msgfmt" too. Where I must execute this comand ? In windows cmd or in Cygwin console ? And why it did't work ? I also installed gettext package
Re: Problem translation .po files
I guess in the Cygwin console. Please ask the Cygwin community if your problem persists.
If you've found out what the problem is, we can add a hint to the article about adding translations:
https://aimeos.org/docs/Developers/Add_translations
If you've found out what the problem is, we can add a hint to the article about adding translations:
https://aimeos.org/docs/Developers/Add_translations
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos,
give us a star
If you like Aimeos,

Re: Problem translation .po files
Ok! Thank you. I will if my problem persist