title: jQuery $.post Callback Function (data) is Undefined
body: <p>I submit a form using jQuery to a php file on my server.
  Everything works... (the php file gets the right post variables, makes a database entry etc.)
  But on the response, sometimes 'data' goes wacky.</p>
  
  <pre><code>$('#form_submit').click( function() {
      $.post("path/to/script.php", $('#form').serialize(), function(data) {
          if ( data.status == 1 ) {
              alert('awesome sauce');
          } else {
              alert('crap');
          }
      }, "json");
  });
  </code></pre>
  
  <p>php script returns (on success)</p>
  
  <pre><code>$response['status'] = 1;
  $response['message'] = 'worked';
  echo json_encode($response);
  exit();
  </code></pre>
  
  <p>I'm getting a whole lot of crap, and not enough awesome sauce.</p>
  
  <p>Does anyone have an idea why sometimes 'data.status' is undefined, and sometimes it isn't?</p>