Invalid form submission in wordpress
You need to pass array('test_form' => FALSE)
as the second parameter or the upload will be rejected for some reason.See http://codex.wordpress.org/Function_Reference/wp_handle_upload#Parameters
Second parameter of wp_handle_upload
is important.
Use array('action' => 'name_of_your_action')
(without prefix admin_post_
or wp_ajax_
).