Storing file name when uploading using Coldfusion

前端 未结 3 1759
遇见更好的自我
遇见更好的自我 2021-01-20 21:13

I am trying to store the filename of the selected file to be uploaded into a hidden input field on the form. my form looks like this

3条回答
  •  一个人的身影
    2021-01-20 21:33

    The filename does not become available until the file is uploaded. This happens after the form is posted. The only way around this is to try posting the fileupload via AJAX and then returning the filename.

    Otherwise, you can assign the value to the field after the file is upload and the form is posted.

        
    

提交回复
热议问题