EasyUI Forum

General Category => EasyUI for jQuery => Topic started by: zzdfc on August 01, 2015, 09:35:13 AM



Title: How to change language from english?
Post by: zzdfc on August 01, 2015, 09:35:13 AM
How to change language from english?


Title: Re: How to change language from english?
Post by: yamilbracho on August 01, 2015, 03:14:40 PM
In the jEasyui download, folder 'locale', you can find translation for many languages. To use just include the appropiate file for your language, for example, if you want spanish messages just :

<script type="text/javascript" src="easyui/locale/easyui-lang-es.js"></script>

HTH,
Yamil


Title: Re: How to change language from english?
Post by: zzdfc on August 01, 2015, 09:35:59 PM
How to change language according to language of browser,please?


Title: Re: How to change language from english?
Post by: yamilbracho on August 02, 2015, 12:33:02 PM
You can get browser language using

var language = window.navigator.userLanguage || window.navigator.language;
alert(language);

Accoring the result you can load the appropiate easyui translation file