title: JSON multi-dimensional array for Ajax post
body: <p>Any ideas if it is possible to serialize HTML fields which are in a multi-dimensional array format for transmission over AJAX post?</p>
  
  <p>Tried serializeArray and that formats 1 level of the array.</p>
  
  <p>Data I need to serialize would be a series of name/value fields e.g. </p>
  
  <pre><code>name="customer" value="the value"
  name="location" value="the location"
  </code></pre>
  
  <p>Using serializeArray() works fine on these e.g.</p>
  
  <pre><code>var formData = $('#createVacancy :input');
  var serializedFormData = formData.serializeArray();
  </code></pre>
  
  <p>But some of the form data uses HTML array notation e.g.</p>
  
  <pre><code>name="tier[1][tiers][5][groupId]" value="5"
  </code></pre>
  
  <p>Result from serializeArray()</p>
  
  <p>Normal name/value pairs comes through like Object <code>{ name="customer_name", value="Test customer name"}</code></p>
  
  <p>But fields which use html array notation come through like:</p>
  
  <pre><code>Object { name="tier[1][publication_date]", value="03 Feb 2011"}, 
  Object { name="tier[1][publication_date_db]", value="2011-02-03"}, 
  Object { name="tier[1][tiers][5][groupId]", value="5"}, 
  Object { name="tier[1][tiers][5][groupName]", value="Diamond"}
  </code></pre>
  
  <p>I'd have though this would need to be broken down into further objects.</p>