Re: Name of uploaded file before cffile

2007-10-10 Thread Ian Skinner
Back from an unintentionally long weekend. I presume the file name is part of the HTTP data sent by the browser through the web server to ColdFusion. If you output the form file field you will see a long random character name of the temporary file created by the web server that is where

Re: Name of uploaded file before cffile

2007-10-10 Thread Matt Williams
Right Ian. I understand that part. But consider this: 1) User uploads myFile.txt 2) CF puts it into c:\temporary\directory\neo12345.tmp 3) Form field value has c:\temporary\directory\neo12345.tmp 4) code calls cffile action=upload ... / 5) If I did not specify a new file name in the destination

Re: Name of uploaded file before cffile

2007-10-10 Thread Ian Skinner
My question, and this is more out of curiosity than anything, is how does CF remember the original user's file name of myFile.txt between steps 3 and 4 above. Looking through the various scopes doesn't seem to reveal it. The form field, as you mentioned is a random name in a temporary directory.

Re: Name of uploaded file before cffile

2007-10-10 Thread Claude Schneegans
My question, and this is more out of curiosity than anything, is how does CF remember the original user's file name of myFile.txt The original name is transmitted in the HTTP request by the browser. This is the purpose of the multipart in the ENCTYPE attribute of the form. One of the parts

Name of uploaded file before cffile

2007-10-05 Thread Matt Williams
Is it possible to get the name of the client's file before doing cffile? I am testing for file size by doing a cfdirectory and filtering on the neoX.tmp file name provided in the form field. If the file size is too large, I would like to tell the user which file (this is a multiple upload

Re: Name of uploaded file before cffile

2007-10-05 Thread Ron Gowen
You could use JS to put the file name in a hidden field before upload. On 10/5/07, Matt Williams [EMAIL PROTECTED] wrote: Is it possible to get the name of the client's file before doing cffile? I am testing for file size by doing a cfdirectory and filtering on the neoX.tmp file name

Re: Name of uploaded file before cffile

2007-10-05 Thread Ian Skinner
I'm pretty sure the answer is no, but just wanted to double-check. Thanks, Yup, the answer is no. Before CF has a chance to do anything, the browser has read the file from the client's machine, bundled it into the response header, sent the whole kit-n-caboodle to the web server, the web

Re: Name of uploaded file before cffile

2007-10-05 Thread Matt Williams
On 10/5/07, Ian Skinner [EMAIL PROTECTED] wrote: I'm pretty sure the answer is no, but just wanted to double-check. Thanks, Yup, the answer is no. Before CF has a chance to do anything, the browser has read the file from the client's machine, bundled it into the response header, sent the

RE: Name of uploaded file before cffile

2007-10-05 Thread Brad Wood
, October 05, 2007 12:00 PM To: CF-Talk Subject: Name of uploaded file before cffile Is it possible to get the name of the client's file before doing cffile? I am testing for file size by doing a cfdirectory and filtering on the neoX.tmp file name provided in the form field. If the file size

Re: Name of uploaded file before cffile

2007-10-05 Thread Matt Williams
file before cffile Is it possible to get the name of the client's file before doing cffile? I am testing for file size by doing a cfdirectory and filtering on the neoX.tmp file name provided in the form field. If the file size is too large, I would like to tell the user which file