The autocomplete functions on the user profile form do not work because of the following JS error:

"TypeError: Drupal.ajax is undefined"

URL:user/[USER-ID]/edit/badges

I've already tried to fix it by adding the following code in function user_badges_change_form($form, &$form_state, $account):

  $form['#attached']['library'][] = array('system', 'drupal.ajax');
  $form['#attached']['library'][] = array('system', 'jquery.form');

Any ideas? It makes the module unusable for this case, that's why I see priority "Major". The problem exists in the latest .dev and the latest 7.x.-1 stable.

Comments

Anybody’s picture

Issue summary: View changes
Anybody’s picture

Status: Active » Closed (works as designed)
Related issues: +#2130941: ajax.js order seems to break Drupal JavaScript

I'm sorry. As I later found out this is caused by a bug in another module (see related issue). The error only leads to the problem, that the autocomplete works no more like described.