If you put your
add_action(‘wp_ajax_someAction’, ‘someCallback’);
inside a function or if block (and I guess any block) it wont work. For example this wont work:
if(…):
add_action(‘wp_ajax_someAction’, ‘someCallback’);
endif;
I would like to know why, anyone?