Supported Versions: PHP 5, PHP 7, PHP 8
List files and directories inside the specified path
<?php scandir(string $directory, int $sorting_order = SCANDIR_SORT_ASCENDING, ?resource $context = null): array|false
<?php         return;

    }



    foreach ((array) scandir($dir) as $file) {

        if ('.' === $file || '..' === $file) {

            continue;

        }