title: JavaScript does not send data to PHP script
body: <p>Firebug writes that request time of this script is 0 and add_comment_processor.php returns NULL.</p>
  
  <pre><code>$(document).ready(function(){
              $("#send_button").click(function(){
                  var request = {
                      'comment': $("#new_comment_textfield").val(), //Value of textfield
                      'anonymously': $(".anonymously").is(':checked') //Value of anonymous check-button
                  }
                  $.ajax({
                      url: 'add_comment_processor.php',
                      type: 'post',
                      dataType: 'json',
                      success: function (data) {
                          var json = $.parseJSON(data);
                          alert(json); //returns NULL, but firebug writes that reques time of this script is 0ms
                      },
                      data: request //name of my object
                  });
              });
          });
  </code></pre>
  
  <p><strong>add_comment_processor.php</strong><br>
  It just returns data it received so it shouldn't cause any problem.</p>
  
  <pre><code>&lt;?php
  unset($authorized_user);
  session_save_path($_SERVER['DOCUMENT_ROOT'].'\session');
  session_start();
  
  $authorized_id=$_SESSION['authorized_user']; //logged user
  
  // Read from POST
  $recieve_data = file_get_contents('php://input');
  
  // decode JSON
  $object = json_decode($recieve_data);
  
  $comment=$object-&gt;comment;
  $anonymously=$object-&gt;anonymously;
  
  $send_array=array(
      'comment'=&gt;$comment,
      'anonymously'=&gt;$anonymously
  );
  
  echo json_encode($send_array);
  exit();
  </code></pre>