fix date bug and redirect upload error page