I think the easiest way would be to create an auxiliar form
to post your data to a new page instead of using $.post
So, this would be the code:
var data;
var counter = 1;
$(.customer_id:checked).each(function(){
data['customer_' + counter] = $(this).val();
});
$('<form action="finance/getReceipt" method="POST" target="_blank" style="display:none">' +
'<input type="hidden" name="data1" value="value-data1" />'
).appendTo("body").submit().remove();
Just change your data1
param to the one you want, or add more if you want.
And that's it. The magic is in using a _blank
target for the form.
Hope this helps. Cheers
PS: The other way would be creating a new window with window.open
and assign its content with javascript.