I want to submit a POST form that contains a textarea field and an input field(s) (type=\"checkbox\" with an arbitrary/variable number of checkboxes) on my website via jQuer
var myCheckboxes = new Array(); $("input:checked").each(function() { data['myCheckboxes[]'].push($(this).val()); });
You are pushing checkboxes to wrong array data['myCheckboxes[]'] instead of myCheckboxes.push
data['myCheckboxes[]']
myCheckboxes.push