Dutch PHP Conference 2025 - Call For Papers

ftp_nb_continue

(PHP 4 >= 4.3.0, PHP 5, PHP 7, PHP 8)

ftp_nb_continueContinues retrieving/sending a file (non-blocking)

Опис

ftp_nb_continue(FTP\Connection $ftp): int

Continues retrieving/sending a file non-blocking.

Параметри

ftp

Примірник FTP\Connection.

Значення, що повертаються

Returns FTP_FAILED or FTP_FINISHED or FTP_MOREDATA.

Журнал змін

Версія Опис
8.1.0 Тепер параметр ftp має бути примірником FTP\Connection. Раніше очікувався resource.

Приклади

Приклад #1 ftp_nb_continue() example

<?php

// Initiate the download
$ret = ftp_nb_get($ftp, "test", "README", FTP_BINARY);
while (
$ret == FTP_MOREDATA) {

// Continue downloading...
$ret = ftp_nb_continue($ftp);
}
if (
$ret != FTP_FINISHED) {
echo
"There was an error downloading the file...";
exit(
1);
}
?>

add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top