我尝试绘制日期和值,这是我的代码:
function getDaily(vsatid){
$.ajax({
type: "POST",
url: "daily_graph.php",
data: "id=" + vsatid,
success: function(obj1){
options.series[0].data = obj1.date;
options.series[1].data = obj1.ebno;
}
var chart = new Highcharts.Chart(options);
});}
谁能告诉我我想如何推动这个系列,这样我就可以得到 x 作为日期时间和 y 作为值。下面是我使用 json_encode 从 mysql 数据库解析到 json 的数据。
[{"date":"1363700566","ebno":8.04},{"date":"1363701638","ebno":8.02},{"date":"1363705226","ebno":7.93},{ "日期":"1363709087","ebno":7.65},{"日期":"1363712661","ebno":7.69},{"日期":"1363716221","ebno":7.44},{"日期":"1363719708","ebno":7.19},{"date":"1363723254","ebno":6.97},{"date":"1363726853","ebno":6.99},{"date": "1363730481","ebno":7.04},{"date":"1363734045","ebno":6.92},{"date":"1363737697","ebno":7.07},{"date":"1363741201 ","ebno":7.27},{"日期":"1363744878","ebno":7.35},{"date":"1363748625","ebno":7.48},{"date":"1363752211","ebno":0},{"date":"1363755741" ,"ebno":7.69},{"date":"1363759347","ebno":7.76},{"date":"1363762894","ebno":7.83},{"date":"1363766640"," ebno":7.82},{"date":"1363770121","ebno":7.82},{"date":"1363773789","ebno":7.69},{"date":"1363777209","ebno" :6.78},{"日期":"1363780874","ebno":8.15}]"1363755741","ebno":7.69},{"date":"1363759347","ebno":7.76},{"date":"1363762894","ebno":7.83},{"date":"1363766640 ","ebno":7.82},{"date":"1363770121","ebno":7.82},{"date":"1363773789","ebno":7.69},{"date":"1363777209", "ebno":6.78},{"日期":"1363780874","ebno":8.15}]"1363755741","ebno":7.69},{"date":"1363759347","ebno":7.76},{"date":"1363762894","ebno":7.83},{"date":"1363766640 ","ebno":7.82},{"date":"1363770121","ebno":7.82},{"date":"1363773789","ebno":7.69},{"date":"1363777209", "ebno":6.78},{"日期":"1363780874","ebno":8.15}]{“日期”:“1363777209”,“ebno”:6.78},{“日期”:“1363780874”,“ebno”:8.15}]{“日期”:“1363777209”,“ebno”:6.78},{“日期”:“1363780874”,“ebno”:8.15}]
所有答案都将不胜感激..关于马鲁斯