javascript - How to change "defaultOptions" lang in highCharts dynamically -
i have highcharts trying internationalize. set default
defaultoptions ={... lang: { loading: 'loading...', months: ['january', 'february', 'march', 'april', 'may', 'june', 'july', 'august', 'september', 'october', 'november', 'december'], ...}
i have properties file, , method writes in properties.
methodtowrite['highcharts.months.array']();
but when
lang:{ loading: methodtowrite['highcharts.months.loading'](); months: methodtowrite['highcharts.months.array'](); }
the chart doesnt show up. have feeling i'm inserting methodtowrite
wrong way. methodtowrite
works fine , correctly coded. using in other js files.
try changing semi-colons commas. e.g
lang:{ loading: methodtowrite['highcharts.months.loading'](), months: methodtowrite['highcharts.months.array']() }
check methodtowrite'highcharts.months.loading' returns string , methodtowrite'highcharts.months.array' returns array.
example: http://jsfiddle.net/8zurx/
Comments
Post a Comment