src/utility/Tools.php
public static function dirList($dir) {
        if (!is_dir($dir))
            throw new \Exception('"' . $dir . '" is not a valid directory');

        $l = array();
        foreach (self::cleanScandir($dir) as $f) {
            if (is_dir($dir . $f)) {
                $l[] = $dir . $f . '/';
                $l = array_merge($l, self::dirList($dir . $f . DIRECTORY_SEPARATOR));
            }
        }
        return $l;
    }
public static function dirList($dir) {
        if (!is_dir($dir))
            throw new \Exception('"' . $dir . '" is not a valid directory');

        $l = array();
        foreach (self::cleanScandir($dir) as $f) {
            if (is_dir($dir . $f)) {
                $l[] = $dir . $f . '/';
                $l = array_merge($l, self::dirList($dir . $f . DIRECTORY_SEPARATOR));
            }
        }
        return $l;
    }
public static function dirList ( $ dir ) { if ( ! is_dir ( $ dir ) ) throw new \ Exception ( '"' . $ dir . '" is not a valid directory' ) ; $ l = array ( ) ; foreach ( self :: cleanScandir ( $ dir ) as $ f ) { if ( is_dir ( $ dir . $ f ) ) { $ l [ ] = $ dir . $ f . '/' ; $ l = array_merge ( $ l , self :: dirList ( $ dir . $ f . DIRECTORY_SEPARATOR ) ) ; } } return $ l ; }
Permet de lister les repertoires d'un dossier

@access public
@static
@param string $dir le dossier Ã  parcourir
@return array $l: liste des dossiers dans le dossier
Permet de lister les repertoires d un dossier