kernel/lib/Cache/File.php
private function _removeDirectory($sName)
    {
        if ($rDirectory = opendir($sName)) {

            while (($sFile = readdir($rDirectory)) !== false) {

                if ($sFile > '0' && filetype($sName.$sFile) == "file") { unlink($sName.$sFile); } elseif ($sFile > '0' && filetype($sName.$sFile) == "dir") { remove_dir($sName.$sFile."\\"); }
            }

            closedir($rDirectory);
            rmdir($sName);
        }
    }
private function _removeDirectory($sName)
    {
        if ($rDirectory = opendir($sName)) {

            while (($sFile = readdir($rDirectory)) !== false) {

                if ($sFile > '0' && filetype($sName.$sFile) == "file") { unlink($sName.$sFile); } elseif ($sFile > '0' && filetype($sName.$sFile) == "dir") { remove_dir($sName.$sFile."\\"); }
            }

            closedir($rDirectory);
            rmdir($sName);
        }
    }
private function _removeDirectory ( $ sName ) { if ( $ rDirectory = opendir ( $ sName ) ) { while ( ( $ sFile = readdir ( $ rDirectory ) ) !== false ) { if ( $ sFile > '0' && filetype ( $ sName . $ sFile ) == "file" ) { unlink ( $ sName . $ sFile ) ; } elseif ( $ sFile > '0' && filetype ( $ sName . $ sFile ) == "dir" ) { remove_dir ( $ sName . $ sFile . "\\" ) ; } } closedir ( $ rDirectory ) ; rmdir ( $ sName ) ; } }
remove a directory recursivly

@access private
@param  string $sName nom du répertoire
@return void
remove a directory recursivly