title: send and decode JSON array
body: <p>I'm trying to encode and send JSON array to php page and add it to mysql:</p>
  
  <pre><code>var data = $('form').serialize();
  $.ajax({
      type: 'POST',
      url: 'naujas.php',
      dataType: 'json',
      data: ({
          json: JSON.stringify(data)
      }),
      success: function () {
          $('#naujas').load('naujas.php');
      }
  });
  </code></pre>
  
  <p>But I think its not working I'm getting response from php like that: <code>pav=1&amp;ppav=2&amp;kiekis=3&amp;kaina=4d&amp;ppav=5&amp;kiekis=6&amp;kaina=7&amp;ppav=8&amp;kiekis=9&amp;kaina=0</code></p>
  
  <p>php file</p>
  
  <pre><code>&lt;?php
      $json = json_decode($_POST['json']);
      echo $json;
  ?&gt;
  </code></pre>
  
  <p>What I'm doing wrong?</p>