Skip to content

Instantly share code, notes, and snippets.

@bodrovis
Created May 8, 2019 17:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bodrovis/cd9817f20f96e910e736a22e4e36088e to your computer and use it in GitHub Desktop.
Save bodrovis/cd9817f20f96e910e736a22e4e36088e to your computer and use it in GitHub Desktop.
jQuery(function($) {
var current_user = {
name: "Alex"
};
var consultant = { // <---
name: "Ann",
gender: "female",
message: "How may I help you?"
};
$.i18n().load({
'en': 'http://localhost/lok/jqi/i18n/en.json',
'ru': 'http://localhost/lok/jqi/i18n/ru.json'
}).done(function() {
$('#welcome').text(
$.i18n('welcome', current_user.name)
);
$('#consulting_chat').text( // <---
$.i18n('consulting_info', consultant.name, consultant.gender, consultant.message)
);
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment