ftp_size
PHP 4, PHP 5, PHP 7, PHP 8
ftp_size - Returns the size of the given file
Manual
ftp_size(
FTP\Connection$ftp,
string$filename ): int
ftp_size returns the size of the given file in bytes.
Note:
Not all servers support this feature.
Parameters
- ftp
-
An FTP\Connection instance.
- filename
-
The remote file.
Return Values
Returns the file size on success, or -1 on error.
Changelog
Version | Description |
8.1.0 | The ftp parameter expects an FTP\Connection instance now; previously, a resource was expected. |