You are here

function reference_option_limit_js in Reference field option limit 7

Ajax callback for the updated term reference field.

1 string reference to 'reference_option_limit_js'
reference_option_limit_field_attach_form in ./reference_option_limit.module
Implements hook_field_attach_form().

File

./reference_option_limit.module, line 576
reference_option_limit.module

Code

function reference_option_limit_js($form, $form_state) {

  // We stored the path of the form element we need to return earlier on.
  $form_return_element = drupal_array_get_nested_value($form, $form_state['reference_option_limit_ajax_return']);
  if ($messages = theme('status_messages')) {
    $form_return_element['messages'] = array(
      '#markup' => '<div class="views-messages">' . $messages . '</div>',
    );
  }
  return $form_return_element;
}