Invalid form Submission in WordPress wp_handle_upload
- Article
- Comment
Invalid form Submission in WordPress wp_handle_upload. Sometime, we face the issue of `Invalid form Submission` . I have a solution for the problem. It actually occurs when you pass single argument to the `wp_handle_upload`. your code might be like the below one.
$file = wp_handle_upload($_FILES['upload_file']);
You have to add one more parameter with it.
$file = wp_handle_upload($_FILES['upload_file'], array('test_form' => FALSE));
This one solves your problem .