I am thinking that this is all above my head. I tried modifying the upload.cfm and putting this. But cannot seem to reference the variables.
<cffile action="upload" filefield="AdPhoto" accept="#APPLICATION.ATTACHTYPE#" destination="#APPLICATION.IMAGEPATH#images-ads\cats#Val(ClassAdForPhotos.SCa tegoryID)#\" nameconflict="makeunique"> <cfset RenamePhoto = "#Val(adid)#-#DateFormat(Now(), "yyyymmdd")##TimeFormat(now(), "HHmmss")#.#File.serverFileExt#"> <cffile action="rename" source="#APPLICATION.IMAGEPATH#images-ads\cats#Val(ClassAdForPhotos.SCategor yID)#\#File.ServerFile#" destination="#APPLICATION.IMAGEPATH#images-ads\cats#Val(ClassAdForPhotos.SCa tegoryID)#\#Trim(RenamePhoto)#"> ----- Original Message ----- From: "Rick Root" <[EMAIL PROTECTED]> To: "CF-Talk" <[email protected]> Sent: Monday, December 04, 2006 11:46 AM Subject: Re: FCKEditor? > Doug Brown wrote: > > Ok, thanks Rick. Another question after RTFM I am using the FCK default > > upload and have the images going into webroot/mySite/userFiles/images. Once > > the user uploads to this directory, how can I associate it with the > > information in the database? What I need to do is be able to delete the > > images when and if the ad gets deleted (Classifieds app). > > Also, keep in mind that users may upload the same image for multiple > ads... or they may use the same name for multiple images... make sure > your code handles that, possibly by modifying the CFFILE upload piece in > upload.cfm to force unique filenames rather than overwrite. > > Or maybe you've got a session var with an AD ID in it, you could just > put the images into a subfolder named after the ad id. > > Rick > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Create robust enterprise, web RIAs. Upgrade & integrate Adobe Coldfusion MX7 with Flex 2 http://ad.doubleclick.net/clk;56760587;14748456;a?http://www.adobe.com/products/coldfusion/flex2/?sdid=LVNU Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:262774 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

