0
我想從php腳本導出一些數據加載到arborjs,問題是php json_encode封裝節點和邊緣對象在方括號[]
,這擾亂了arborjs。Arborjs閱讀json數據表格php通過json_encode
json_encode給出:
{"nodes":[{"10":{"auth":"EP","depth":0}}]}
但arborjs希望
{"nodes":{"10":{"auth":"EP","depth":0}}}
其他人遇到和解決的呢?