Issue #1893400 by swentel, dawehner: Fixed Autocomplete is busted.
parent
0b17f26aa7
commit
0143d50f5d
|
@ -4096,11 +4096,13 @@ function form_process_autocomplete($element, &$form_state) {
|
||||||
$element['#attached']['library'][] = array('system', 'drupal.autocomplete');
|
$element['#attached']['library'][] = array('system', 'drupal.autocomplete');
|
||||||
// Provide a hidden element for the JavaScript behavior to bind to. Since
|
// Provide a hidden element for the JavaScript behavior to bind to. Since
|
||||||
// this element is for client-side functionality only, and we don't want to
|
// this element is for client-side functionality only, and we don't want to
|
||||||
// collect any input from it, use #theme='hidden' instead of #type='hidden'.
|
// collect any input from it, use #theme = 'input__hidden' and #pre_render =
|
||||||
|
// 'form_pre_render_hidden' instead of #type='hidden'.
|
||||||
// @todo Refactor autocomplete.js to accept Drupal.settings instead of
|
// @todo Refactor autocomplete.js to accept Drupal.settings instead of
|
||||||
// requiring extraneous markup.
|
// requiring extraneous markup.
|
||||||
$element['autocomplete'] = array(
|
$element['autocomplete'] = array(
|
||||||
'#theme' => 'hidden',
|
'#theme' => 'input__hidden',
|
||||||
|
'#pre_render' => array('form_pre_render_hidden'),
|
||||||
'#attributes' => array(
|
'#attributes' => array(
|
||||||
'id' => $element['#id'] . '-autocomplete',
|
'id' => $element['#id'] . '-autocomplete',
|
||||||
'value' => url($element['#autocomplete_path'], array('absolute' => TRUE)),
|
'value' => url($element['#autocomplete_path'], array('absolute' => TRUE)),
|
||||||
|
|
Loading…
Reference in New Issue