The syntax will vary depending on the action attribute used.
Executes File Transfer Protocol (FTP) commands and can be used to implement a connection to an FTP server, for connection caching, or to implement file and directory operations.
action (Required)
FTP operation to perform which can be one of the following: open, close, changedir, createDir, listDir, removeDir, getFile, putFile, rename, remove, getCurrentDir, getCurrentURL, existsDir, existsFile, and exists.
username (Required if action = "open")
Username to use during the FTP operation. If not using a cached connection, this tag is also required for directory and file commands.
password (Required if action = "open")
Password for the username. If not using a cached connection, this tag is also required for directory and file commands.
server (Required if action = "open")
FTP server to which to connect, such as www.exampleserver.com.
timeout (Optional)
Default: 30. Value in seconds for the timeout of all operations, including individual data request operations.
port (Optional)
Default: 21. Remote port to connect.
connection (Optional)
Name of the FTP connection. This can be used to cache a new FTP connection or for connection reuse.
proxyServer (Optional)
Name of a proxy server or servers to use if proxy access is necessary.
retryCount (Optional)
Default: 1. Number of retries until failure is reported.
stopOnError (Optional)
Default: No
Yes. Halts processing and displays an appropriate error.
No. Populates these variables:
cfftp.succeeded. yes or no.
cfftp.errorCode. Error number.
cfftp.errorText. Message text, which is the text for the error message.
passive (Optional)
Default: No. The Yes enables passive mode.
name (Required if action = "listDir")
Query name of directory listing.
ASCIIExtensionList (Optional)
Default: txt, htm, html, cfm, cfml, shtm, shtml, css, asp, asa. Delimited list of file extensions that force ASCII transfer mode if the transferMode = "auto".
transferMode Optional)
Default: auto. Options include ASCII FTP transfer mode, Binary FTP transfer mode, and Auto FTP transfer mode.
failIfExists (Optional)
Default: Yes. If a local file with the same name exists, then getFile fails.
directory (Required if action = "changedir/createDir/listDir/existsDir")
Directory on which to perform an operation.
localFile (Required if action = "getFile/putFile")
Name of the file on the local system.
remoteFile (Required if action = "getFile/putFile/existsFile")
Name of the file on the FTP server.
item (Required if action = "exists/remove")
Object of these actions: file or directory.
existing (Required if action = "rename")
Current name of the file or directory on the remote server.
new (Required if action = "rename")
New name of file or directory on the remote server.
proxyServer (Optional)
Name of the proxy server or servers to use if proxy access is necessary.
passive (Optional)
Default: No. Yes enables passive mode.
The following query objects are returned by CFFTP when action = "listdir".
Use the syntax queryname.querycolumn to access data.
Name
Filename of the current object.
Path
File path of the current object.
URL
Complete URL for the current object.
Length
File size of the current object.
LastModified
Unformatted date/time value of the current object.
Attributes
Attributes of the current object can be normal or directory.
IsDirectory
Whether object is a file or directory.
Mode
Applies only to Solaris and HP-UX. This is the permissions set on the file as an octal number, such as 644 or 777.