Title: Visualizations that reference json files
Last modified: August 21, 2016

---

# Visualizations that reference json files

 *  Resolved [janro](https://wordpress.org/support/users/janro/)
 * (@janro)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/visualizations-that-reference-json-files/)
 * Hi,
 * I was wondering if anyone has tried visualizations that reference json files.
   I for example can’t get this one to work:
    [http://bl.ocks.org/herrstucki/4327678](http://bl.ocks.org/herrstucki/4327678)
   And I was wondering if there’s something in there the plugin can’t handle.
 * [https://wordpress.org/plugins/wp-d3/](https://wordpress.org/plugins/wp-d3/)

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [Ruben](https://wordpress.org/support/users/figurebelow/)
 * (@figurebelow)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/visualizations-that-reference-json-files/#post-4618720)
 * Hi,
 * Some of the examples in [figurebelow.com ](http://figurebelow.com) load data 
   from .csv files which in practice is the same as loading a .json file.
    The json
   from your example is [this](http://bl.ocks.org/herrstucki/raw/4327678/aa6f466b7600651bd57838ca70b72ce07e79165d/ch.json),
   if you add it to your media library you should be able to referenciate it as 
   an include file in the chart editor
 *  [alwaysalready](https://wordpress.org/support/users/alwaysalready/)
 * (@alwaysalready)
 * [11 years, 12 months ago](https://wordpress.org/support/topic/visualizations-that-reference-json-files/#post-4618815)
 * Sorry, old post I know, but just in case, I managed to do this by writing a function
   in functions.php that first gets data through a json query and then passes it
   to a function written in the wp-d3 chart manager window. It’s important to not
   pass the json data to the function until the svg ‘canvas’ is drawn and you know
   you have all the data.
 * If you need any elaboration let me know.
 *  [strikingconcepts](https://wordpress.org/support/users/strikingconcepts/)
 * (@strikingconcepts)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/visualizations-that-reference-json-files/#post-4618822)
 * How did you find the path to the json file from this example [http://bl.ocks.org/herrstucki/4327678](http://bl.ocks.org/herrstucki/4327678)?
 *  Plugin Author [Ruben](https://wordpress.org/support/users/figurebelow/)
 * (@figurebelow)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/visualizations-that-reference-json-files/#post-4618823)
 * Hi,
 * The quickest way is to use Firebug or similar in your browser to see where the
   file is read from.
    Alternatively you can always check the code, although this
   sometimes is more confusing (in the map from the example the filename was contained
   inside a javascript map). Often happens that the files is just placed in the 
   same folder where the html page is.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Visualizations that reference json files’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wp-d3_bda39b.svg)
 * [Wp-D3](https://wordpress.org/plugins/wp-d3/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-d3/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-d3/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-d3/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-d3/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-d3/reviews/)

 * 4 replies
 * 4 participants
 * Last reply from: [Ruben](https://wordpress.org/support/users/figurebelow/)
 * Last activity: [11 years, 4 months ago](https://wordpress.org/support/topic/visualizations-that-reference-json-files/#post-4618823)
 * Status: resolved