modify json output for easier parsing
I want to use the json api plugin together with the d3.js library to produce dynamic visualizations of my wordpress data. My problem is that the default root that the plugin’s api produces means that I cannot simply call the resulting json back as in d3.json(“url”, function(error, root)), because parsing from the root will create problems.
As I see it, there are two options: 1. Customize the output of the json file or 2. specify the parsing level of the json file (i.e. replace “root” in the above function)
It seems to me that the second option would be simpler but in any case I don’t know how to do either of the two.
I’d really appreciate anybody’s help on this.
- The topic ‘modify json output for easier parsing’ is closed to new replies.