0
我有簡單的line chart。 由於某些原因,這並不顯示任何行,但是,我認爲我的數據沒有問題。爲什麼?d3 js基本折線圖,數據問題
data = '[{"date":"18-Jun-14","amount":"5"},{"date":"19-Jul-14","amount":"30"},{"date":"18-Aug-14","amount":"138"},{"date":"18-Sep-14","amount":"110"},{"date":"18-Oct-14","amount":"217"},{"date":"18-Nov-14","amount":"342"}]';
另一個問題是,評論數據(下),我從PHP腳本得到我應該改變爲適當的格式。這是可能的,或者我應該改變PHP輸出?
/*data='[{"date":"2014-Jun-18","amount":"5"},{"date":"2014-Jul-18","amount":"30"},{"date":"2014-Aug-18","amount":"138"},{"date":"2014-Sep-18","amount":"110"},{"date":"2014-Oct-18","amount":"217"},{"date":"2014-Nov-18","amount":"342"}] ';*/