>- see footer for list info -<
This would happen if the file failed to upload, and thus the destination
folder would be the temp folder as you never saved it elsewhere.
As you have error trapping and are limiting the file types that can be
uplaoded, I would first check that an error is not occuring do to an invalid
filetype.

Russ 

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Paul Swingewood
Sent: 14 January 2007 14:17
To: [email protected]
Subject: [CF-Dev] cffile - firefox

>- see footer for list info -<
I have an application which uploads pictures using cffile.

The problem with fire fox is that its writing this to the database

C:\CFusionMX\runtime\servers\default\SERVER-INF\temp\wwwroot-tmp\neotmp1633.
tmp

Can anyone PLEASE help me sort this. I have no idea how to code this
differently to resolve the problem,

The Code .....

<CFTRY>
        <!--- UPLOAD THE PROPERTY DETAILS --->
        <cffile action ="UPLOAD"
        filefield ="details"
        nameconflict = "overwrite"
        accept = "application/pdf"
        destination = "#application.uploadDetails#">

<cfif #file.filewassaved# eq "yes"><!--- Were the details saved? --->
        <cfset details = '#file.serverfile#'>
        <!---<cfdump var="#CFFILE#" label="first upload">---> </cfif>
<CFCATCH><CFSET errormessage = "Please enter a file"></CFCATCH> </CFTRY>

<CFTRY>
<!--- UPLOAD THE SMALL PROPERTY PICTURE ---> <cffile action ="UPLOAD"
filefield ="smallpic"
nameconflict = "overwrite"
accept = "image/jpg, image/pjpeg"
destination = "#application.UploadDirectory#"> <cfif #file.filewassaved# eq
"yes"><!--- Was the small pic saved? --->
        <cfset smallpic = '#trim(file.serverfile)#'>
        <!---<cfdump var="#CFFILE#" label="Second upload">
        <cfabort>--->
<!---<cfelse>
        The picture was not saved
        <cfabort>--->
</cfif>
<CFCATCH><CFSET errormessage = "Please enter a file"></CFCATCH> </CFTRY>


<!--- Add the property to the database ---> <CFQUERY NAME="AddProperty"
datasource="#application.DSN#">
                        INSERT INTO tblPropertyDetails
                                (NoBedroomsIDFK,
                                PropertyTypeIDFK,
                                PropertyLocationIDFK,
                                RoadName,
                                Picture,
                                Description1,
                                Description2,
                                Description3,
                                Description4,
                                Description5,
                                Description6,
                                SellingPrice,
                                PostCode,
                                PDFDetails)
                        VALUES
                                ('#form.Select_Bedrooms#',
                                '#form.Select_Type#',
                                '#form.Select_Location#',
                                '#trim(form.RoadName)#',
                                '#trim(smallpic)#',
                                '#trim(form.Description1)#',
                                '#trim(form.Description2)#',
                                '#trim(form.Description3)#',
                                '#trim(form.Description4)#',
                                '#trim(form.Description5)#',
                                '#trim(form.Description6)#',
                                CAST('#FORM.SellingPrice#' AS MONEY),
                                '#trim(PostCode)#',
                                '#trim(Details)#')
                                SELECT @@IDENTITY AS NewID
                </CFQUERY>


The PDF for the property details works fine its just the picture....

HELP !!!!

Regards - Paul


_______________________________________________

For details on ALL mailing lists and for joining or leaving lists, go to
http://list.cfdeveloper.co.uk/mailman/listinfo

--
CFDeveloper Sponsors:-
>- cfdeveloper Hosting provided by www.cfmxhosting.co.uk -<
>- Lists hosted by www.Gradwell.com -<
>- CFdeveloper is run by Russ Michaels, feel free to volunteer your help 
>-<


_______________________________________________

For details on ALL mailing lists and for joining or leaving lists, go to 
http://list.cfdeveloper.co.uk/mailman/listinfo

--
CFDeveloper Sponsors:-
>- cfdeveloper Hosting provided by www.cfmxhosting.co.uk -<
>- Lists hosted by www.Gradwell.com -<
>- CFdeveloper is run by Russ Michaels, feel free to volunteer your help -<

Reply via email to