2 Replies Latest reply on Sep 16, 2006 3:48 AM by azadisaryev

    CFFIile action="upload" uploads fiel sto wwwroot-tmp folder

      I see that opther poeple have posted similar problems but none quite like mine. In my case CFFILE is putting the file I am uploading into a location in the wwwroot-tmp folder but not as a TMP file. The actual file resides there within other sub-folders whose path matches the actual path I am trying to upload the file to but the actual file never makes it to that folder. In otherwords if I am trying to put a file in inetpub\wwwroot\hss\resumes the files ends up in wwwroot-tmp\hss\resumes.

      This particular site I am having this problem with was just move from another of my servers where it was not having this problem.

      Any help would be greatly appreciated.

      Rick Harris
        • 1. Re: CFFIile action="upload" uploads fiel sto wwwroot-tmp folder
          Abinidi Level 1
          Is this a Windows machine? if so then
          destination="\inetpub\hss\clients\resumes\" needs to be the full path


          and also lose the trailing slash to the path.
          • 2. Re: CFFIile action="upload" uploads fiel sto wwwroot-tmp folder
            azadisaryev Level 1
            destination attribute of cffile tag must point to an absolute path, not relative. otherwise the file will be placed in the CF temp folder.

            the best way to pass the destination value to the cffile tag is to first cfset the path using
            <cfset dest = "#ExpandPath('[put relative path to destination dir from your current dir here, with trailing backslash]')#"> (see example below)
            then use <cffile destination='#dest#' ...>

            be sure to use a rel path notation in the ExpandPath function! i.e. if you are currently in root/folder1/ and you want to upload your file to root/images/ then the cfset will be:
            <cfset dest="#ExpandPath('..\images\')#">