Added logic to upload the file and send in form submission