PHP ftp_get_option()Functions
Complete PHP FTP Reference Manual
Definition and Usage
The ftp_get_option() function returns various runtime options for an FTP connection.
Syntax
ftp_get_option(ftp_connection,option)
| Parameters | Description |
|---|---|
| ftp_connection | Required. Specifies the FTP connection to use. |
| option | Required. Specifies the runtime option to return. Possible values:
|
Examples
<?php
$conn = ftp_connect("ftp.testftp.com") or die("Could not connect");
ftp_login($conn,"admin","ert456");
echo ftp_get_option($conn,FTP_TIMEOUT_SEC);
ftp_close($conn);
?>
$conn = ftp_connect("ftp.testftp.com") or die("Could not connect");
ftp_login($conn,"admin","ert456");
echo ftp_get_option($conn,FTP_TIMEOUT_SEC);
ftp_close($conn);
?>
The above code will output:
90
Complete PHP FTP Reference Manual Other Extensions