title: Error get value in array when using input checkbox
body: <p>I have a sample:</p>
  
  <pre><code>&lt;input type="checkbox" id="in-category-1" name="post_category[]" value="1"&gt;
  &lt;input type="checkbox" id="in-category-2" name="post_category[]" value="2"&gt;
  &lt;input type="checkbox" id="in-category-3" name="post_category[]" value="3"&gt;
  &lt;input type="checkbox" id="in-category-4" name="post_category[]" value="4"&gt;
  &lt;input type="checkbox" id="in-category-5" name="post_category[]" value="5"&gt;
  </code></pre>
  
  <p>And jquery:</p>
  
  <pre><code>var selectednumbers = [];
  jQuery('input[type=checkbox]').each(function(i, selected) {
     selectednumbers[i] = jQuery(selected).val();
  });
  alert(selectednumbers);
  </code></pre>
  
  <p>=> error can't get value when checked and uncheck</p>