|
eio_readdirReads through a whole directory Description
resource eio_readdir
( string
$path
, int $flags
, int $pri
, callable $callback
[, string $data = NULL
] )
Reads through a whole directory(via the opendir, readdir and
closedir system calls) and returns either the names or an array in
Parameters
Return Values
eio_readdir returns request resource on success, or
Node types:
ExamplesExample #1 eio_readdir example
<?php The above example will output something similar to: my_readdir_callback called data: NULL result: array(2) { ["names"]=> array(7) { [0]=> string(7) "archive" [1]=> string(8) "articles" [2]=> string(8) "incoming" [3]=> string(7) "innfeed" [4]=> string(8) "outgoing" [5]=> string(8) "overview" [6]=> string(3) "tmp" } ["dents"]=> array(7) { [0]=> array(3) { ["name"]=> string(7) "archive" ["type"]=> int(4) ["inode"]=> int(393265) } [1]=> array(3) { ["name"]=> string(8) "articles" ["type"]=> int(4) ["inode"]=> int(393266) } [2]=> array(3) { ["name"]=> string(8) "incoming" ["type"]=> int(4) ["inode"]=> int(393267) } [3]=> array(3) { ["name"]=> string(7) "innfeed" ["type"]=> int(4) ["inode"]=> int(393269) } [4]=> array(3) { ["name"]=> string(8) "outgoing" ["type"]=> int(4) ["inode"]=> int(393270) } [5]=> array(3) { ["name"]=> string(8) "overview" ["type"]=> int(4) ["inode"]=> int(393271) } [6]=> array(3) { ["name"]=> string(3) "tmp" ["type"]=> int(4) ["inode"]=> int(393272) } } } |