Creates a new FTP upload request object
Agent
Name | Type | Description |
---|---|---|
URL | String |
The URL to which the body will be uploaded
|
body | String or blob |
The data to upload
|
An httprequest object
Warning FTP functionality has been deprecated and will shortly be removed. You should not make use of the ftp object and its methods in new applications, and existing applications should be updated to use an alternative file-transfer mechanism, such as HTTP.
This method returns an httprequest object primed to make an FTP PUT request. The request isn’t issued until either httprequest.sendsync() or httprequest.sendasync() is called on the returned httprequest object.
The contents of the body parameters will be uploaded and stored with the name specified in the URL.
The URL may be in any form suitable for FTP, such as "ftp://host:port/path"
for anonymous retrieval or "ftp://user:password@host:port/path"
where a username and password are required. The URL must start with "ftp:"
— ie. it must include the colon. FTPS is not supported.
See either of the ‘send’ methods listed above for information on status code values indicating success or failure (eg. login denied).