charmingduck
asked on
drupal ajax web form
i have web form and web form block modules installed
how do i apply ajax to the form?
how do i apply ajax to the form?
This module can do it, http://drupal.org/project/ajax. Never used it before though.
ASKER
i tried it with web form and web form block, didnt work, any ideas?
Look at this page, http://www.lullabot.com/articles/modifying-forms-drupal-5-and-6, under "Find the form ID". You'll need to find the id of your webform block form.
Then put the following code snippet in your theme's template.tpl.php (sounds familiar?). Replace THEMENAME, and YOUR-FORM-ID with your values.
Then put the following code snippet in your theme's template.tpl.php (sounds familiar?). Replace THEMENAME, and YOUR-FORM-ID with your values.
THEMENAME_form_alter(&$form, $form_state, $form_id) {
if($form_id == 'YOUR-FORM-ID') {
$form['#ajax'] = array(
'enabled' => TRUE
);
}
}
ASKER
I used the ajax module and it broke my site,,,
but after i disabled it, everything's back to normal...
but after i disabled it, everything's back to normal...
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
any difference between uninstall a module and simply uncheck it?
Yes, unchecking disables the module, uninstalling removes all data related to that module. So that way when you enable it again you get a fresh start. Some modules can't be uninstalled because they don't create any data to remove.