I'm having an issue with uploading or looping through the the file names of my images to my database table. I am able to select various images and upload the selected image on my local machine to a specific folder that I designate. After the image files are put into my folder, I am having some difficulties because I want to insert the file names of the images that I just inserted into my folder, into my database. I'm trying to use the cffile parameters to do that. My question: Being that it is multiple files being uploaded at once, do I need to do a cfloop on a cfquery insert in order to capture and insert the names into my database? My attempt at the code is below. The upload work just fine. But It chokes out at the insert portion. What do you think could be the issue? <cfparam name="form.fileUpload3" default=""> <cfif len(trim(form.fileUpload3))> <cffile action="uploadall" fileField="fileUpload3" destination="#cookie.c.webpathmultipleimages#" accept = "image/jpeg, image/png, image/jpeg" nameconflict="makeunique"> <!---This is where i'm running into my issue---> <cfloop INDEX="i" LIST="#Form.fileUpload3#"> <cfquery name="addtoimage"> insert into image (imaid, imacomid, imaname) Value ( '00', '#cookie.communityID#', '#file.clientfile#') </cfquery> </cfloop> </cfif> Thanks for any help you can provide...
... View more