Jump to content

Problem with numbers when set locale in translation

Featured Replies

Posted

The previous problem on RC5 was that days and months strings was always on English but forum localisation is Russian.

Ok, I've installed locales to server and set right locale "ru_RU.UTF-8" to localisation, but after it all numbers shows with incorrect character. Where is a problem?

 2015-03-17_23h53_06.thumb.png.aee51b6d74

Open the .xml file translation with notepad, save it in UTF-8 and then reload.

  • Author

Open the .xml file translation with notepad, save it in UTF-8 and then reload.

​Thanks, but it didn't help. And all strings from langpack displayed normal, the problem only with numbers. May be there is a problem with LC_NUMERIC?

You entered a comma instead of a period after the thousands? Ex: 12.000. This problem occurs if you enter a comma instead of a period.

  • Author

You entered a comma instead of a period after the thousands? Ex: 12.000. This problem occurs if you enter a comma instead of a period.

​It's IPB generated numbers: count of replies in topics, count of users posts etc.

Andrey, there is something wrong in the Russian translation, in English you have the same problem?

  • Author

Andrey, there is something wrong in the Russian translation, in English you have the same problem?

​Sure, the same problem if I delete localisation package and leave English only.

If I set default locale as en_US.UTF-8, the 10000 will be displayed as 10,000. If I set locale for English package as ru_RU.UTF-8, it will be displayed as 10?000.

I've asked my hosting support, they answer me:

We don't think that the problem in server settings, it looks like it's forum problem.

Only one note - if the forum gets the data from MySQL in the formatted form, you MySQL configuration look like this:
| Character_set_client | latin1 |
| Character_set_connection | latin1 |
| Character_set_database | latin1 |
| Character_set_filesystem | binary |
| Character_set_results | latin1 |
| Character_set_server | latin1 |
| Character_set_system | utf8 |
| Character_sets_dir | / usr / share / mysql / charsets / |

In general, there may be some compatibility issue, but in general it is very unlikely.

In fact, it requires to investigate the source code of the script online, find a place, where a conclusion including a separator, to understand how it forms the output and why at this point there is a problem, but to provide such assistance, we unfortunately can not.
The only thing - made a search in the file system for the keyword number_format, here are the results, I hope they will help you:

./applications/core/setup/upg_30007/queries.json
./applications/core/interface/ace/mode-twig.js
./applications/core/interface/ace/mode-php.js
./applications/core/interface/ace/mode-ftl.js
./applications/core/interface/codemirror/codemirror.js
./applications/core/data/theme.xml
./datastore/template_1_c8c276c9a99811c050a8036df5d2db06_forms.d6e937aa1d.ipsstore
./system/Lang/Lang.php
./system/3rd_party/tcpdf/include/tcpdf_static.php

Would you please send me a copy of your translation? I am convinced that there was a problem of creating language or loaded.

Thanks.

Andrey, checks whether this language attachment works, but first remove the one you have right now, create a new language Русский (RU) and from the drop down select always Русский (RU). When you load this crwato language that you send, then let me know if it works.

Русский (RU).rar

  • Author

Enzo,

Thanks, I did it - removed old language pack and uploaded your attachment. But it didn't resolve the issue. All numbers stay corrupted if I set Russian locale.

I did not know that your work was locally. Then follow these steps: language-> Create new-> charge and enter the file you have attached. Locally also the Italian does not recognize him and follow this procedure. Try it and let me know. Have a nice day.

screenshot.png

  • Author

language-> Create new-> charge and enter the file you have attached. Locally also the Italian does not recognize him and follow this procedure. Try it and let me know. Have a nice day.

Hi Enzo, I did the steps but it didn't help me. So probably the issue not in language pack I think.
Thank you so much for your help.

Archived

This topic is now archived and is closed to further replies.

Recently Browsing 0

  • No registered users viewing this page.