fixes #2300 Form redirect issue with file or image uploads