I have these checkboxes :
<input name="linkStyle" type="checkbox" name="style[]" value="Style1" />
<input name="linkStyle" type="checkbox" name="style[]" value="Style2" />
<input name="linkStyle" type="checkbox" name="style[]" value="Style3" />
and this jQuery function :
<script type="text/javascript">
$(document).ready(function() {
$('input[name=linkStyle]').click(function(e) {
e.preventDefault();
$('#browseForm').submit();
});
});
</script>
but in fact it doesnt send to the server the style[] array trought the form. Why? And how can I fix this trouble? Tried also removing e.preventDefault(); but nothing change…
Try —
HTML
jQuery