0

I have a problem regarding loading data files from an external server with d3, queue.js respectively. Basically what I want to do is to have my d3 graphs on multiple webservers, but the underlying data should be maintained centralized on a single webserver. So what I have in my code for the graphs is

  filenames_root = "http://www.myserver.com/data/";
  root_names = [ "1", "2", "3" ];

  var q = queue() 
              .defer(d3.json,filenames_root + "this_is_a.json");                    

  root_names.forEach( function (rn) { 
           q = q.defer(d3.csv,filename_root + rn + ".csv" ); 
      } );
  q.await(main);

However, when loading this code, the debugger halts indefinitely at

  q.await(main)

Any idea on how to overcome this problem is appreciated!

PS: I'm fairly new to JavaScript and web development, so please bear with me in case I made a beginner's mistake! I couldn't find anything regarding this problem on the web though.

Lars Kotthoff
  • 107,425
  • 16
  • 204
  • 204
Benjamin Maier
  • 522
  • 6
  • 14

0 Answers0