native

ezhttp_ftp_download

Syntax

native EzHttpRequest:ezhttp_ftp_download(
    const user[] = "",
    const password[] = "",
    const host[] = "",
    const remote_file[] = "",
    const local_file[] = "",
    const on_complete[] = "",
    EzHttpFtpSecurity:security = EZH_UNSECURE,
    EzHttpOptions:options_id = EzHttpOptions:0
);

Description

Downloads a file from a remote server using FTP.

Parameters

user The user name to use for the FTP connection.
password The password to use for the FTP connection.
host The host to connect to.
remote_file The remote file to download.
local_file The local file to save to. If the remote path uses wildcard matching
or this argument points to a directory, downloaded files keep their remote names.
on_complete The function to call when the download is complete.
Signature: public on_complete(EzHttpRequest:request_id)
security Member of EzHttpFtpSecurity. The security strategy use for the FTP connection.
Passing any other value raises a native error.
options_id The options to use for the request.

Return

The request handle.