I am trying to change the hello text from the messenger plugin. I have a website in French and English and I would like to have
Hi how can we help you? (in English) and
Ia ora na, comment peut-on vous aider ?( in French)
I used the Messenger Customer Chat plugin. I added the text from the backend but it opens a window and loads Facebook settings. I can select a default language but I can't add a translation. I can switch to another plugin if needed. I saw there is also the function to add hello text from woocommerce. Let me know if it works best with this one for the translation.
So you are adding this in Facebook. Not in you site.
WPML works in your site. not in the facebook.
So technically, translating this is impossible.
In this case, you can use another plugin that compatible with WPML.
You can check here: https://wpml.org/account/downloads/ for a list of compatible plugins.
Just type "chat" in the search field and you will get the list.
Let me know if you need anything else regarding this.
I've added the following code to the function fbmcc_inject_messenger() of facebook-messenger-customer-chat.php and it works fine:
if( get_option( 'fbmcc_pageID' ) != '' ) {
$genCode = "";
$the_tags = array(
"fr" => array("fr_FR","Bonjour, Comment pouvons-nous vous aider ?"),
"en" => array("en_US","Hi, How can we help you ?"),
"es" => array("es_ES","Hola, ¿cómo podemos ayudarte?"),
"nl" => array("nl_NL","Hallo, hoe kunnen we je helpen?"),
"de" => array("de_DE","Hallo, wie können wir Ihnen helfen?")
);
$cur_lang = ICL_LANGUAGE_CODE;
$genCode = "
<div id='fb-root'></div>
<script> (function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
js = d.createElement(s);
js.id = id;
js.src = '<em><u>hidden link</u></em>".$the_tags[$cur_lang][0]."/sdk/xfbml.customerchat.js#xfbml=1&version=v6.0&autoLogAppEvents=1';
fjs.parentNode.insertBefore(js, fjs);
} (document, 'script', 'facebook-jssdk'));
</script>
<div class='fb-customerchat'
attribution='wordpress'
attribution_version='1.7'
page_id='[my_page_ID]'
theme_color='#whatever_you_want'
greeting_dialog_display='hide'
logged_in_greeting='".$the_tags[$cur_lang][1]."'
logged_out_greeting='".$the_tags[$cur_lang][1]."'>
</div>
";
Manage Cookie Consent
We use cookies to optimize our website and services. Your consent allows us to process data such as browsing behavior. Not consenting may affect some features.
Functional
Always active
Required for our website to operate and communicate correctly.
Preferences
The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
Statistics
We use these to analyze the statistics of our site. Collected information is completely anonymous.The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
Marketing
These cookies track your browsing to provide ads relevant to you.