دنبال کننده ها

۱۳۹۶ آبان ۱۰, چهارشنبه

javascript - HighCharts getJson - Unable to display

[ad_1]



Json Returned by my Server




"data": [
"name": "name",
"data": ["[Date.UTC(2017, 01, 25), 89]",
"[Date.UTC(2017, 01, 26), 99]",
"[Date.UTC(2017, 02, 02), 106]",
"[Date.UTC(2017, 02, 04), 102]",
"[Date.UTC(2017, 02, 07), 110]",
"[Date.UTC(2017, 10, 31), 155]"]
]



The code i'm using is from just data is generated by me (Above)
https://www.highcharts.com/demo/spline-irregular-time



My Javascript Code



Please Remove one T from bit ly
$.getJSON('http://bitt.ly/2zpoZqT', function (csv)
console.log(csv['data']);
Highcharts.chart('container',
chart:
type: 'spline'
,
title:
text: 'Keyword Tracking'
,
subtitle:
text: 'Top 20 Keywords'
,
xAxis:
type: 'datetime',
dateTimeLabelFormats: // don't display the dummy year
month: '%e. %b',
year: '%b'
,
title:
text: 'Date'

,
yAxis:
title:
text: 'Snow depth (m)'
,
min: 0
,
tooltip:
headerFormat: '<b>series.name</b><br>',
pointFormat: 'point.x:%e. %b: point.y:.2f m'
,

plotOptions:
spline:
marker:
enabled: true


,

series: csv['data']
);

);



[ad_2]

لینک منبع