Empty response after a callback in form_alter I am trying to add a new field in a preexistent form and invoke a callback.
The response of the callback is alway an error with an empty response:


  An AJAX HTTP error occurred.
  HTTP Result Code: 200
  Debugging information follows.
  Path: /system/ajax
  StatusText: OK
  ResponseText: 
  &nbsp; 


ResponseText is always empty.

The code I use in my_form_form_alter() is the following.

$form['country_views_exposed_form'] = array(
  '#type' =&gt; 'select',
  '#title' =&gt; t('Country'),
  '#options' =&gt; array(
    'sl'  =&gt; 'Select...',
    'au'  =&gt; 'Australia',
    'nz'  =&gt; 'New Zealand'
  ),
  '#ajax' =&gt; array(
    'callback' =&gt; '__my_callback',
    'wrapper' =&gt; 'country-views-exposed-form-wrapper-',
    'method' =&gt; 'replace',
    'event' =&gt; 'change'
  ),
  '#attributes' =&gt; array('class' =&gt; 'views-exposed-widget')
);


All I put in __my_callback() produces the same result: I don't get a clean response.

function __my_callback(&amp;$form, &amp;$form_state) { 
  return $form['states_views_exposed_form'];
}
I have resolved.
Exposed form fields don't are the same of 'normal' form fields in drupal. I have applied the patch #46 listed here: http://drupal.org/node/1183418