I am trying to make my own tree in D3.js, but I am having trouble figuring out how to make one. I have looked at the following links:
http://bl.ocks.org/1249394#interactive_tree.css
d3js Tree square
and even tried copying them to get something working so that I can tinker, but it won't work for me. I have riddled the code with alerts and in both the pedigree and the collapsible tree the code stops working right after the d3.json call. I copied the json files too and renamed them so that they were the same. In the pedigree example
d3.json("info.json", function(json) {
alert(json);
var nodes = tree.nodes(json);
alert('hi');
So here the first alert works and the second doesn't, and this happens in both examples. If anybody knows why, an explanation or fix would be greatly appreciated. Thanks!!!
I figured out that when d3.json("localhost...", callback) is called it is returning null. I read on another post that there are cross domain restrictions. I am not really sure what that means or how to fix it
I have tried it both locally from the same directory as I am running my application from and I have tried it from my Xamp server. And still when the alert(json) is called it shows null.