|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Hi,
I am new at Coldfusion.Please excuse me if the question sounds stupid. I am trying to upload a file on the server and i get the following error. Upload works when i tried to do the same in Development on my local machine using Destination : C:/Apachegroup/apache/htdocs/xyz/file/ Error processing CFFILE The directory specified in the DESTINATION attribute of the CFFILE tag (//IPADDRESSof Server/ora/file/ ) is not valid. The directory either does not exist or is not accessible by the ColdFusion service. The error occurred while processing an element with a general identifier of (CFFILE), occupying document position (79:2) to (82:21) in the template file C:\website\michigan\member\admin\Upload_detail_form.cfm The specific sequence of files included or processed is: C:\WEBSITE\MICHIGAN\MEMBER\ADMIN\UPLOAD_DETAIL_FORM.CFM . Date/Time: 09/21/05 13:30:45 Browser: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322) Remote Address: 65.241.241.174 HTTP Referer: http://wesite name/member/admin/uploadfile.cfm?issue_no=2&did=1 Template: C:\website\michigan\member\admin\Upload_detail_form.cfm Query String: issue_no=2&did=1. I think the problem is in the Address I am specifying for the DESTINATION. I tried to give the IP address of the server as destination but that didnt work either (//IP Address/XyZ/File/) Please Help! |
|
#2
|
|||
|
|||
|
First, make sure the account that the CF server is running under has write permissions to the share. If that doesn't work, try using a mapped drive instead of a UNC path.
__________________
Ask if you have a question, but also help answer questions that you have knowledge of! Thanks, Brian. How to Post a Question in the Forums |
|
#3
|
||||
|
||||
|
happened to me 2 was the write permissions in my case, also when you do a cffile its a good idea to use the cftry tag so users dont get a nasty error message. Heres an example
Code:
<cftry>
<cffile action="upload"
accept="image/jpeg,image/jpg,image/pjpeg"
filefield="UploadFile"
destination="C:\CFusionMX7\wwwroot\Alas\pics\"
nameconflict="makeunique">
<cfcatch type="ANY">
<CFSET COOKIE.ERROR = "ON">
<SCRIPT language="JavaScript"> top.location.replace("gobacktooriginalpage.cfm"); </SCRIPT>
</cfcatch>
</cftry>
then on the orginal page you say if error=on then show some error message saying user messed up. |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ColdFusion Development > CFFile Tag Upload errors out |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|