Open a secure SSL-FTP connection:
The ftp_ssl_connect() function opens a secure SSL-FTP connection.
When the connection is open, you can run FTP functions against the server.
Note: This function is only available if both the ftp module and the OpenSSL support is built statically into PHP.
Parameter | Description |
---|---|
host | Required. Specifies the FTP server address. Can be a domain address or an IP address. This parameter should not be prefixed with "ftp://" or have any trailing slashes |
port | Optional. Specifies the port to connect to. Default is 21 |
timeout | Optional. Specifies the timeout for network operations. Default is 90 seconds |
Return Value: | Returns a SSL-FTP stream on success or FALSE on error |
---|---|
PHP Version: | 4.3+ |
PHP Changelog: | In PHP 5.2.2 this function returns FALSE if it cannot use an SSL connection, instead of fallbacking to a non-SSL connection |