
PHP smazání obsahu složky
Chtěl bych pomocí php smazat obsah složky pokus
Proč mi to takto nic nesmaže?
<?php
function delTree($dir) {
$files = glob( $dir . 'pokus/', GLOB_MARK );
foreach( $files as $file ){
if( is_dir( $file ) )
delTree( $file );
else
unlink( $file );
}
}
?>