The example on php.net works for my script. But I don't understand what $cmd does.
Thanks
http://us4.php.net/manual/en/function.rmdir.php
<?php
// this wipes the entire
// directory clean (empty or not)
$path = "/path/to/empty";
$cmd = "rm -rf $path";
$cmd;
?>