How to change language key.
I had strugle with this and i want to share. in order to change keys of a module for instanse timeline you need to go the module folder->install->lang and duplicate the language file (en.xml) . change en.xml to xy.xml (xy you language) and inside change the parameters as your language module setting
-
- · Baloo
- ·
Hello Hodor, If you want to create another language, you will need to follow the method perfectly described here https://github.com/unaio/una/wiki/Creating-new-language-module
-
- · Hodor Hodor
- ·
Thanks i skipped one step there 😅
-
- · Hodor Hodor
- ·
I still can't change system key's which located under english module. I tried various ways but with no success. my language module created as described above.
-
- · Baloo
-
·
In reply to Hodor Hodor
- ·
Hello, I do not understand, your module installs since I tested it at home, what problem do you have more precisely?
-
- · Hodor Hodor
- ·
it did not worked for me...
did you installed it and manged to translate, recompile and see the changes? (system's keys)
-
- · Baloo
-
·
In reply to Hodor Hodor
- ·
Sorry hodor, I did not see your answer. Let's be clear. Where do you translate? In the xml files of your module or on una?
-
- · Hodor Hodor
- ·
una has a module called english which holds all system key's. i want to translate the keys there. what i have done so far it duplicate en.xml to he.xml and translated some keys. then i went to developer and recompile hebrew (english) and nothing has changed
-
- · Baloo
-
·
In reply to Hodor Hodor
- ·
Please, make a copy / pasted of the first 5 line of he.xml that you translated.
-
- · Hodor Hodor
- ·
<?xml version="1.0" encoding="utf-8"?>
<resources name="he" flag="il" title="Hebrew">
<string name="_ADM_PROFILE_SEND_MSG"><![CDATA[ההודעה נשלחה בהצלחה.]]></string>
<string name="_ATT_ACTIVE_E"><![CDATA[אתה חבר מלא התכונות של הקהילה שלנו. עם זאת, תוכל להשעות את הפרופיל שלך באופן זמני עבור אחרים.]]></string>
<string name="_ATT_APPROVAL_E"><![CDATA[הפעלת הפרופיל שלך מתבצעת. בדרך כלל זה לוקח עד 24 שעות. תודה על הסבלנות.]]></string>
-
- · Baloo
-
·
In reply to Hodor Hodor
- ·
I looked at the module you sent me, it looks OK, BUT!
What I see is this:
1. Your module to the structure modules/ hebrew / hebrew / => (data), (install), (template)
According to your config.php file, it is not correct, you must have this:
/ modules / avren / hebrew / => (data), (install), (template)2. 1 - ALL .xml files in the folder / data / langs / must be renamed to he.xml
Currently only 1 is done, the one in the data / langs / system / folder
All others in data / langs / data / bx_accounts, bx_acl, bx_albums, etc. must be adapted as well, for now they are all ru.xml.2.2 - For ALL, you must also change the second line like this.
<resources name="he" flag="he" title="Hebrew">
3. I do not know where you left off what you copied above, but in the module you sent me, I see:
<resources name="he" flag="he" title="Hebrew">
<string name="_ADM_PROFILE_SEND_MSG"><![CDATA[Message was successfully sent.]]></string>
<string name="_ATT_ACTIVE_E"><![CDATA[You are a full-featured member of our community. You can, however, suspend your profile to become temporarily unavailable for others.]]></string>
<string name="_ATT_APPROVAL_E"><![CDATA[Your profile activation is in progress. Usually it takes up to 24 hours. Thank you for your patience.]]></string>
Conclusion: it is normal that it does not go :-)
1 . Disable your module
2. Uninstall
3. Remove folder module
Correct all this, and replace your module well in / module / avren / hebrew / => (data), (install), (template) -
- · Hodor Hodor
- ·
Can you explain point 1 please, how do i change it?
-
- · Baloo
-
·
In reply to Hodor Hodor
- ·
1. In the directory /modules/ create a directory "avren", you will have /modules/avren/
Your module:
It must be a "hebrew" folder which contains the files 'data' - 'install' - 'template'
You must upload the folder your module "hebrew" in /modules/avren/
You will have in the end /modules/avren/hebrew/ => 'data' - 'install ' - ' template 'NOT
/modules/avren/hebrew/hebrew/ => 'data' - 'install ' - ' template 'I am attaching the example of my "french" file, I can not be clearer ...