That will usually work on Unix but will not work on Windows. Rather than
executing an external program you can use PHP itself to do a recursive
delete.
There are examples at http://www.php.net/manual/en/function.rmdir.php if
you read the user notes you will see several posts about doing this.
Jas
Can't do wildcards like * because thats something that as I found out a few
days ago, is expanded by the shell into a full command, so because your not
running a shell, it can't be expanded and the raw unlink call to *.* fails because
the unlink function doesn't understand wildcards. If you
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hey,
You can't delete the files all at onceyou have to delete them one by one
or use this function that will remove full directories.
- -
function force_rmdirs($dir) {
$dh = opendir($dir);
while(false !== ($file = readdir($dh))) {
3 matches
Mail list logo