Tag

scandir

1 views collected around this technical thread.

php中文网 Courses
php中文网 Courses
Dec 29, 2023 · Backend Development

How to Traverse Directories and Retrieve File Information in PHP

This article explains how to use PHP functions such as opendir, readdir, is_dir, and scandir to open directories, read file names, perform recursive traversal of subfolders, and retrieve file information, providing clear code examples for each method.

PHPdirectory traversalopendir
0 likes · 5 min read
How to Traverse Directories and Retrieve File Information in PHP
Laravel Tech Community
Laravel Tech Community
Jul 17, 2021 · Backend Development

PHP scandir Function: List Files and Directories in a Specified Path

The PHP scandir function returns an array of filenames and sub‑directories from a given directory, optionally sorted in ascending or descending order, and can accept a stream context, providing FALSE on failure and generating a warning if the path is not a directory.

BackendPHPdirectory
0 likes · 2 min read
PHP scandir Function: List Files and Directories in a Specified Path
Laravel Tech Community
Laravel Tech Community
Mar 12, 2021 · Backend Development

PHP scandir() Function: Description, Parameters, Return Values, and Example

This article explains PHP's scandir() function, detailing its syntax, parameters, return values, and provides sample code demonstrating directory listing with optional sorting and context options, along with the expected output for developers.

BackendPHPfilesystem
0 likes · 2 min read
PHP scandir() Function: Description, Parameters, Return Values, and Example