Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

cffileupload question

Status
Not open for further replies.

jimmyshoes

Programmer
Jun 1, 2008
132
GB
Code:
<cffile action="upload" filefield="form.FileToUpload" 
destination="d:\home\your_domain.com\[URL unfurl="true"]wwwroot\uploads\"[/URL] nameConflict="makeUnique">

<cfset Uploaded_File_Name = CFFile.ClientFile>

<CFOUTPUT>File: [#Uploaded_File_Name#]</CFOUTPUT>

Is it possible to replicate this code using cffile action="uploadall" to cfoutput all the uploaded file names. I want to do this on the server side

Thanks
 
The above code does work with 'uploadall'. I had an error elsewhere.

cffile.serverFile contains the file name of the last file to be uploaded ( not an array ). This works fine for me, each time a file is uploaded I can write to the database to record it. If say 4 files are uploaded then the database is accessed 4 times. When using <cffileupload> with a number of files, I think the action file is called each time a file is uploaded
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top