(PHP 4, PHP 5, PHP 7, PHP 8)
readdir — Read entry from directory handle
Returns the name of the next entry in the directory. The entries are returned in the order in which they are stored by the filesystem.
Returns the entry name on success, або false в разі помилки.
Ця функція може
повертати як логічне false, так і не логічне значення, яке прирівнюється до
false. Докладніше про це описано в розділі Логічні типи даних. Для перевірки
значення, яке повертає ця функція, використовується оператор ===.
| Версія | Опис |
|---|---|
| 8.5.0 |
Using null for dir_handle is now deprecated.
Instead, the last opened directory handle should be explicitly provided.
|
| 8.0.0 |
dir_handle is now nullable.
|
For a complete example refer to the opendir() documentation.