Ajax form works on page but not on block
Did you create the form in a separate file?  If you did, then it makes a big difference where in the main .module file you put the module_load_include() function to bring in the form.  I had this problem because my form definition was in a .inc file, but when I moved module_load_include() from hook_node_view() to hook_init(), it worked fine.

Edit:  Wait, better answer:  hook_init() isn't called on cached pages, so may not be the way to go.  Instead, call module_load_include() wherever it makes sense (e.g., hook_node_view() or hook_block_view()), but use form_load_include() within your form definition, like this:

function my_ajax_test_node_form($form, &amp;$form_state) {
  form_load_include($form_state, 'inc', 'my_ajax_test', 'my_ajax_test.forms');
  $form['my_ajax_test_div'] = array(
    '#type' =&gt; 'container',
    '#tree' =&gt; TRUE,
    '#prefix' =&gt; '&lt;div id="my-ajax-test-form-div"&gt;',
    '#suffix' =&gt; '&lt;/div&gt;',
  );
  return $form;
}


Once the file has been loaded with form_load_include(), it will be loaded anytime the form is called.