I have been searching for this a lot but all the tutorial on the net only show how to create an ajax form with
#ajax on the submit button if you want to submit the whole form.
What I am trying to achieve is this: I've got a custom form with lots of checkboxes, all of which set values in an array stored in
$_SESSION. When I attach
#ajax to a checkbox the form gets replaced, but the
$_SESSION array does not change as if the form as a whole has not been submitted.
How can I achieve that when I click on a checkbox the form submits as if I clicked on the submit button and the
$_SESSION array is set correctly?
Thanks a lot in advance.