| 7 ajax_example.module | ajax_example_autocheckboxes_callback($form, $form_state) |
| 8 ajax_example.module | ajax_example_autocheckboxes_callback($form, $form_state) |
Callback element needs only select the portion of the form to be updated. Since #ajax['callback'] return can be HTML or a renderable array (or an array of commands), we can just return a piece of the form. See @link ajax_example_advanced.inc AJAX Advanced Commands for more details on AJAX framework commands.
Return value
renderable array (the checkboxes fieldset)
Related topics
1 string reference to 'ajax_example_autocheckboxes_callback'
File
- ajax_example/
ajax_example.module, line 334 - AJAX Examples module file with basic examples.
Code
function ajax_example_autocheckboxes_callback($form, $form_state) {
return $form['checkboxes_fieldset'];
}
Login or register to post comments