Dostupnost ve verzích: PHP 5.0
List files and directories inside the specified path
| Parametr | Datový typ | Výchozí hodnota | Poznámka |
|---|---|---|---|
$directory |
string |
není | The directory that will be scanned. |
$sorting_order |
int |
null, | By default, the sorted order is alphabetical in ascending order. If the optional sorting_order is set to non-zero, then the sort order is alphabetical in descending order. |
$context |
resource |
null | For a description of the context parameter, refer to the streams section of the manual. |
array
an array of filenames on success, or false on
failure. If directory is not a directory, then
boolean false is returned, and an error of level
E_WARNING is generated.
Autor článku pracuje jako seniorní vývojář a software architekt v Praze. Navrhuje a spravuje velké webové aplikace, které znáte a používáte. Od roku 2009 nabral bohaté zkušenosti, které tímto webem předává dál.
Rád vám pomůžu:
Pomohu vám zavést AI do vašeho projektu – od analýzy a návrhu řešení až po nasazení do produkce. Ušetřete čas, zjednodušte procesy a získejte konkurenční výhodu.
Domluvit konzultaciNabízím trénink vývojářů, konzultace, školení a analýzu návrhových vzorů. Osobně v Praze nebo online.
Napište miNejlepsi tipy a triky o PHP do Vaseho e-mailu. Clanky a novinky nejen ze sveta PHP a programovani.