title: working with JSON data, trying to parse nested data
body: <p>I just working with JSON data and am playing around with jQuery and Ajax requests. Pretty basic stuff, but here's my problem.</p>
  
  <p>I have a basic data set which I was using for time tracking. I know how to parse the simple JSON data like this:</p>
  
  <pre><code>{
          "end" : "1/18/2011",
          "start" : "1/18/2011",
          "task" : "Code Review",
  },
  </code></pre>
  
  <p>It's the more complicated stuff I'm trying to parse like this where I'm trying to pull the "time" data out.</p>
  
  <pre><code>  {
          "end" : "1/17/2011",
          "start" : "1/17/2011",
          "task" : "Exclusive Brands",
          "time" : {
             "analysis" : 4,
             "documentation" : 3,
             "meetings" : 2
          }
  </code></pre>
  
  <p>This is the code for the script I've been using to parse the simple data:</p>
  
  <pre><code>$(function() {
      $('.load').click(function(){
          $.getJSON("data.js",function(data){
              $.each(data.timesheet, function(i,data){
              var div_data ="&lt;div class='box'&gt;"+data.start+" "+data.task+"&lt;/div&gt;";
              $(div_data).appendTo("#time-tracking");
                  });
              }
          );
          return false;
      });
  });
  </code></pre>
  
  <p>My question is what's the format to parse the <code>time</code> data, or what's the best way to parse the information nested inside the <code>time</code> element? </p>
  
  <p>Any help will be greatly appreciated.    </p>