Suggestion Box
Add possibility for users to choose interface language of chat

Please, add possibility for users to choose interface language of chat.
This feature will be very useful possibility on multilingual sites.

For example, i am from Russia, i'm going to site, the site is multilingual, i'm choosing russian site language, but chat is still on english... and i can't change it's language and use it on my native russian.... - not convenient trifle :)

Please, add possibility for users to choose interface language of chat. This feature will be very useful possibility on multilingual sites. For example, i am from Russia, i'm going to site, the site is multilingual, i'm choosing russian site language, but chat is still on english... and i can't change it's language and use it on my native russian.... - not convenient trifle :)

Me too: +1 for it:).
In my case the user choice the language when he/she log in, freichat should automatically detect that choice.

Me too: +1 for it:). In my case the user choice the language when he/she log in, freichat should automatically detect that choice.

In my website the user have to choose the language at logging in. The choice is saved in $_SESSION['lng'], so I modified the arg.php substituing the following line:

$this->lang = $parameters['lang']; //Language please do not include .php here only file name

with the following code:

if (isset($_SESSION['lng'])) {
if ($_SESSION['lng'] == 'sw') {
$this->lang = 'swahili';
} elseif ($_SESSION['lng'] == 'it') {
$this->lang = 'italian';
} else {
$this->lang = 'english';
}
} else {
$this->lang = $parameters['lang']; //Language please do not include .php here only file name
}

It seems to work.
NinoV

In my website the user have to choose the language at logging in. The choice is saved in $_SESSION['lng'], so I modified the arg.php substituing the following line: $this->lang = $parameters['lang']; //Language please do not include .php here only file name with the following code: if (isset($_SESSION['lng'])) { if ($_SESSION['lng'] == 'sw') { $this->lang = 'swahili'; } elseif ($_SESSION['lng'] == 'it') { $this->lang = 'italian'; } else { $this->lang = 'english'; } } else { $this->lang = $parameters['lang']; //Language please do not include .php here only file name } It seems to work. NinoV

Glad to hear you got it working.

Glad to hear you got it working.
Necessity is the mother of all inventions!

Unfortunately it doesn't effect all messages ;(( especially the one in js files!

Unfortunately it doesn't effect all messages ;(( especially the one in js files!

Which js messages are you talking about ?

Setting $this->lang to a particular language is equivalent to changing the language through the backend .
So it should reflect on all your messages .

Which js messages are you talking about ? Setting $this->lang to a particular language is equivalent to changing the language through the backend . So it should reflect on all your messages .
Necessity is the mother of all inventions!

In some files the messages are hardcoded, for example in freichat.js:

...


I am available
\n\
...
Here we will have some options for the chatroom
\n\
....

I tried to use this line:

"+freidefines.TRANS.default_status+"
\n\

but it didn't work.
In some files the messages are hardcoded, for example in freichat.js: ... <div class='frei_option_bar_status_txt' id='frei_option_bar_status_txt'>I am available</div></div>\n\ ... <div class='frei_chatroom_options' id='frei_chatroom_tools'>Here we will have some options for the chatroom</div>\n\ .... I tried to use this line: <div class='frei_option_bar_status_txt' id='frei_option_bar_status_txt'>"+freidefines.TRANS.default_status+"</div></div>\n\ but it didn't work.
I am available\n\

That is just dummy text, it shouldn't be visible to the users . Same goes for the other one
<em>I am available\n\</em> That is just dummy text, it shouldn't be visible to the users . Same goes for the other one
Necessity is the mother of all inventions!

But it isn't translated. Besides "Set status" is only in freichat.js
Please see the attached screenshot.

Thanks,
Nino

But it isn't translated. Besides "Set status" is only in freichat.js Please see the attached screenshot. Thanks, Nino

No, we checked again, they are just dummy text, The actual content is available in the translation file

$frei_trans['default_status']


But, it won't affect immediately if you change this, because it is stored in the session .

Besides "Set status" is only in freichat.js
We have added them in our next release .

No, we checked again, they are just dummy text, The actual content is available in the translation file <code>$frei_trans['default_status']</code> But, it won't affect immediately if you change this, because it is stored in the session . <em>Besides "Set status" is only in freichat.js</em> We have added them in our next release .
Necessity is the mother of all inventions!

This morning it "I am available" wasn't translated, as shown in the screenshot, but now it is correctly translated! I don't understand why!

Can I myself add $frei_trans['sett_status'] in the translation file?

Thanks

This morning it "I am available" wasn't translated, as shown in the screenshot, but now it is correctly translated! I don't understand why! Can I myself add $frei_trans['sett_status'] in the translation file? Thanks

We will be releasing the next version tomorrow (Jan 10) . So we recommend you install the new version since it has many new translations in the language file

This morning it "I am available" wasn't translated, as shown in the screenshot, but now it is correctly translated! I don't understand why!
We explained this in the previous reply, this is because the status is stored in the session and remains till the user closes the browser.

We will be releasing the next version tomorrow (Jan 10) . So we recommend you install the new version since it has many new translations in the language file <em>This morning it "I am available" wasn't translated, as shown in the screenshot, but now it is correctly translated! I don't understand why!</em> We explained this in the previous reply, this is because the status is stored in the session and remains till the user closes the browser.
Necessity is the mother of all inventions!

>We explained this in the previous reply,
Sorry I skipped that line!

Thanks a lot,
Nino

>We explained this in the previous reply, Sorry I skipped that line! Thanks a lot, Nino

Hi,

I've noticed that if I choose my language, Italian, and other users choose their own language, I see their "I am available" in their language and not in mine.

I think that it would be better to show that message in my choosen language and not in theirs.

Is that possible?

Thanks.
Nino V

Hi, I've noticed that if I choose my language, Italian, and other users choose their own language, I see their "I am available" in their language and not in mine. I think that it would be better to show that message in my choosen language and not in theirs. Is that possible? Thanks. Nino V
I think that it would be better to show that message in my choosen language and not in theirs.

That will become difficult, because you will have to translate the message to the corresponding language which will then require
you to integrate freichat with some translation API provided by either Google, Microsoft, etc.
<em>I think that it would be better to show that message in my choosen language and not in theirs.</em> That will become difficult, because you will have to translate the message to the corresponding language which will then require you to integrate freichat with some translation API provided by either Google, Microsoft, etc.
Necessity is the mother of all inventions!

I thought that it could be translated using the user settings. Anyway you know your code better than me ;)
Thanks for your attention and your excellent work,
Nino

I thought that it could be translated using the user settings. Anyway you know your code better than me ;) Thanks for your attention and your excellent work, Nino
I thought that it could be translated using the user settings

Yes, it can be translated if the user keeps his status as 'I am available'. But what if he changes his status into something else in his own language ?
You will then have to translate his custom status to your own language. This is obviously impossible without a translation API .
Just thought of letting you know: We have released FreiChat V9.6 just now.
<em>I thought that it could be translated using the user settings</em> Yes, it can be translated if the user keeps his status as 'I am available'. But what if he changes his status into something else in his own language ? You will then have to translate his custom status to your own language. This is obviously impossible without a translation API . Just thought of letting you know: We have released FreiChat V9.6 just now.
Necessity is the mother of all inventions!

I've downloaded the new version. Do I have to reinstall anew or there is an update procedure? I searched in the site but I've not found a guide.

Thanks

I've downloaded the new version. Do I have to reinstall anew or there is an update procedure? I searched in the site but I've not found a guide. Thanks

There is no upgrade, you need to install anew. But you can skip the last step of installation .

There is no upgrade, you need to install anew. But you can skip the last step of installation .
Necessity is the mother of all inventions!
131
19
0
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft