Some actions must be registered as early as possible. When you put it in the "current_page_function"
method, (depending on your program) it might be too late.
Hence, the wp_ajax_*
hook cannot find your action, and it returns the error.
Some actions must be registered as early as possible. When you put it in the "current_page_function"
method, (depending on your program) it might be too late.
Hence, the wp_ajax_*
hook cannot find your action, and it returns the error.