function ajax_forms_test_lazy_load_form
Form builder: Builds a form that triggers a simple AJAX callback.
3 string references to 'ajax_forms_test_lazy_load_form'
- AJAXFrameworkTestCase::testLazyLoad in modules/
simpletest/ tests/ ajax.test - Test that new JavaScript and CSS files added during an AJAX request are returned.
- AJAXFrameworkTestCase::testLazyLoadOverriddenCSS in modules/
simpletest/ tests/ ajax.test - Tests that overridden CSS files are not added during lazy load.
- ajax_forms_test_menu in modules/
simpletest/ tests/ ajax_forms_test.module - Implements hook_menu().
File
-
modules/
simpletest/ tests/ ajax_forms_test.module, line 484
Code
function ajax_forms_test_lazy_load_form($form, &$form_state) {
$form['add_files'] = array(
'#type' => 'checkbox',
'#default_value' => FALSE,
);
$form['submit'] = array(
'#type' => 'submit',
'#value' => t('Submit'),
'#ajax' => array(
'callback' => 'ajax_forms_test_lazy_load_form_ajax',
),
);
return $form;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.