Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Dowbnload from CFFTP please help

Status
Not open for further replies.

kalo

Technical User
Mar 14, 2003
2
IE
the below code is for the FTP template. it works fine to display files from the "Download" dir from ftp server, but when I click on a file that I want to download, the error default page of the web browser appear saying page can't be displayed...
How can I download a file from this cfftp template?
many thanks

<CFFTP CONNECTION= &quot;Connection&quot;
USERNAME=&quot;user1&quot;
PASSWORD=&quot;user1&quot;
Server=&quot;ftp.ftpserver.com&quot;
ACTION=&quot;Open&quot;
STOPONERROR=&quot;Yes&quot;>
<!--- get dir info --->
<cfftp connection = &quot;Connection&quot;
ACTION=&quot;ListDir&quot;
DIRECTORY=&quot;Download&quot;
NAME=&quot;DirList&quot;
STOPONERROR=&quot;Yes&quot;>

<Table border = 0 cellspacing = 3 width=&quot;100%&quot;>
<tr valign=top>
<td width =&quot;50%&quot;><Strong>Path/name</strong></td>
<td width=&quot;25%&quot;><strong>Size</strong></td>
<td width = &quot;25%&quot;><strong>Last Modified</strong></td>
</tr>

<cfoutput query=&quot;DirList&quot;>
<tr Valign=top>
<td width=50%>
<cfif IsDirectory>
#Name#/
<cfelse>
<a href=&quot;#URL#&quot;>#Name#</a>
</cfif>
</td>
<td width=&quot;25%&quot;>#Length#</td>
<td width=&quot;25%&quot;>#DateFormat(LastModified)#</td>
</tr>
</cfoutput>

</table
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top