QualityUnit
   
Old 30th December 2009, 01:54 AM   #1
jsi
Junior Member
 
Join Date: May 2008
Posts: 19
jsi is on a distinguished road
Default Multiple Language Support?

I have website that is both english and spanish.

How can I make Live Agent work in two languages? Currently my website is easily translated by editing a spanish file and an english file. I have created two sets of buttons. "en" folder for english buttons. "es" folder for spanish buttons.

On my website, in my english file, I added this code to get my english chat since english is my default:
Quote:
<script type="text/javascript" src="http://yourdomain.com/liveagent/chatserver/track.php"></script>
<div>
<a onclick="cs_100.open(); return false" target="_blank">
<img class="cs_100" src="http://yourdomain.com/liveagent/chatserver/button.php" alt="LiveHelp Button"/>
</a>
</div>
So what code do I add or how can LiveAgent support spanish?
In spanish I should have a different code correct? This way the buttons show in spanish and when clicked chatting is in spanish.

LiveAgent has over 10 languages, but it only says how to enable one language at a time. How can I make two languages work at once?

Thanx.
jsi is offline   Reply With Quote
Old 22nd January 2010, 01:29 PM   #2
MatejMilko
Matej Milko, Q. U.
 
Join Date: Apr 2009
Posts: 128
MatejMilko has disabled reputation
Default

This customization requires some PHP coding - you must be able to differ by some variable or by cookie if the user is on the Spanish or English site.
You need to add some PHP code int to the file file :
<your live agent location>/plugins/qunit_chat_user/StatusImageProvider.class.php.

On the line 32 there is the following code: $filename = './img/en/' . $name . '.gif'; You must modify it, the sheme is:
if(is_spanish)$filename = './img/es/' . $name . '.gif';
if(is_english)$filename = './img/en/' . $name . '.gif';

As you can see, you should create the spanish button in the directory img/es with the name online.gif and offline.gif.

Instead of is_spanish and is_english there should be some condition which define on what site the user is. If you use an URL parameter, e.g. for english ?lang=en, then the condition will seem so: if($_GET["lang"]=="en") ...
__________________
Regards

Matej Milko
support team
Quality Unit s.r.o.
MatejMilko is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 11:04 AM.