ahah_example_autocheckboxes_callback

6 autocheckboxes.inc ahah_example_autocheckboxes_callback()

Callback for autocheckboxes. Process the form with the number of checkboxes we want to provide.

1 string reference to 'ahah_example_autocheckboxes_callback'

File

ahah_example/autocheckboxes.inc, line 71
A Self-configure a form based on a select control. Add the number of checkboxes specified in the select.

Code

function ahah_example_autocheckboxes_callback() {
  $form = ahah_example_callback_helper();

  $checkboxes = $form['checkboxes'];
  // Remove the wrapper so we don't double it up.
  unset($checkboxes['#prefix'], $checkboxes['#suffix']);

  $output = theme('status_messages');
  $output .= drupal_render($checkboxes);

  // Final rendering callback.
  drupal_json(array('status' => TRUE, 'data' => $output));
  exit();
}
Login or register to post comments