How to rearrange an array in JQuery
<p>I have this being POSTed to my script</p>

<pre><code>Array
(
  [0] =&gt; Array
      (
          [name] =&gt; test1
          [value] =&gt; test1 value
      )

  [1] =&gt; Array
      (
          [name] =&gt; test2
          [value] =&gt; test2 value
      )
)
</code></pre>

<p>What I want is:</p>

<pre><code>Array
(
  [0] =&gt; Array
      (
          [test1] =&gt; test1 value
      )

  [1] =&gt; Array
      (
          [test2] =&gt; test2 vlaue
      )
)
</code></pre>

<p>This is the JQuery I am using to post the data. Can someone tell me what I need to achieve this?</p>

<pre><code>var vals = $("#post").find('input,select,textarea').serializeArray();
vals.push({
    name: 'article',
    value: CKEDITOR.instances.article.getData()
});
var qs = $.param(vals);

$.post('test.php', {
    data: vals
}, function (data) {
    if(data.success == 0) {

    }
}, 'json');
</code></pre>

<p><strong>EDIT:</strong>
What I am looking to do is to simply access each key value on my server like this:</p>

<pre><code>    echo $_POST['test1'];
...
</code></pre>
