Problem translation .po files

Help for integrating the Laravel package
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!
mvnaz
Posts: 28
Joined: 06 Jan 2017, 21:42

Re: Problem translation .po files

Post by mvnaz » 07 Jan 2017, 16:48

Let me ask, may be I can generate translate .mo file simply, without using unix command ? Do you know ?

mvnaz
Posts: 28
Joined: 06 Jan 2017, 21:42

Re: Problem translation .po files

Post by mvnaz » 07 Jan 2017, 17:36

Nice! My msgfmy working. But I do not know how to go to disk d in cygwin console.

mvnaz
Posts: 28
Joined: 06 Jan 2017, 21:42

Re: Problem translation .po files

Post by mvnaz » 07 Jan 2017, 18:57

I did all as you say but it do not work

it is my ru/po file. File put in myproject/vendor/aimeos/aimeos-core/ext/aimeos-ru-translater/admin/i18n

# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
# Translators:
# Андрей Аксёнов <aksenovaa@bk.ru>, 2014
msgid ""
msgstr ""
"Project-Id-Version: aimeos-core\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-04-21 23:29+0200\n"
"PO-Revision-Date: 2016-06-07 09:37+0000\n"
"Last-Translator: Андрей Аксёнов <aksenovaa@bk.ru>\n"
"Language-Team: Russian (http://www.transifex.com/aimeos/aimeos- ... nguage/ru/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: ru\n"
"Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);\n"

msgid "!="
msgstr "не равно"

msgid "<"
msgstr "перед"

msgid "<="
msgstr "перед (вкл.)"

msgid "=="
msgstr "равно"

msgid "=~"
msgstr "начинается с"

msgid ">"
msgstr "после"

msgid ">="
msgstr "после (вкл.)"

msgid "Search"
msgstr "Поиск"

msgid "~="
msgstr "содержит"

msgid "pay:unfinished"
msgstr "text"

msgid "Latest orders"
msgstr "text"

Also I creat ru file using comand which you write.
But nothing happen. I am worry, it is do not work. Help me please, I think I almost make it ) :o

mvnaz
Posts: 28
Joined: 06 Jan 2017, 21:42

Re: Problem translation .po files

Post by mvnaz » 07 Jan 2017, 19:45

Wow! Yeees! I did it )) Thank you, aimeos! It work)

User avatar
aimeos
Administrator
Posts: 7866
Joined: 01 Jan 1970, 00:00

Re: Problem translation .po files

Post by aimeos » 08 Jan 2017, 16:51

Don't store your new .po file in "myproject/vendor/aimeos/aimeos-core/ext/aimeos-ru-translater/admin/i18n/". It will be overwritten as soon as you execute "composer update"! The file must be in "myproject/ext/aimeos-ru-translater/admin/i18n/"
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

gladgladwrap
Posts: 10
Joined: 27 Jan 2018, 22:10

Re: Problem translating .po file

Post by gladgladwrap » 12 Mar 2018, 19:53

Hello aimeos,

I am able to translate files from the client domain, but unable to translate from controller/frontend domain.

I found the original singular string within the controller/frontend/i18n/en.po file, and my config/shop.php looks like this:

'i18n' => [
'en' => [
'client' => [
'Basket' => ['Shopping Cart'],
'Add to basket' => ['Add to Cart'],
'Incl. %1$s%% VAT' => ['Incl. %1$s%% GST'],
'+ %1$s%% VAT' => ['+ %1$s%% GST'],
'Check' => ['Continue'],
],
'controller/frontend' => [
'No unique article found for selected attributes and product ID \"%1$s\"' => ['I like turtles'],
],
],
],



Does this make sense that the controller/frontend translation is not activating?

Thank you,

Laravel 5.5, Aimeos 2017.10, PHP7.1.14, MacOS
PHP 7.1.14, Aimeos 2017.10, Laravel 5.5.39 (php artisan --version)

User avatar
aimeos
Administrator
Posts: 7866
Joined: 01 Jan 1970, 00:00

Re: Problem translation .po files

Post by aimeos » 13 Mar 2018, 13:19

The basket frontend controller decorators doesn't translate the messages at the moment:
https://github.com/aimeos/ai-controller ... t.php#L122

Are you able to create a pull request for all decorators that fixes the problem?
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

Post Reply