uninstall_supercache() WPSCache 1.0
No Hooks.
Return
Null. Nothing.
Usage
uninstall_supercache( $folderPath ) // from http://www.php.net/manual/en/function.rmdir.php;
Code of uninstall_supercache() uninstall supercache WPSCache 1.7.1
function uninstall_supercache( $folderPath ) { // from http://www.php.net/manual/en/function.rmdir.php
if ( trailingslashit( constant( 'ABSPATH' ) ) == trailingslashit( $folderPath ) )
return false;
if ( @is_dir ( $folderPath ) ) {
$dh = @opendir($folderPath);
while( false !== ( $value = @readdir( $dh ) ) ) {
if ( $value != "." && $value != ".." ) {
$value = $folderPath . "/" . $value;
if ( @is_dir ( $value ) ) {
uninstall_supercache( $value );
} else {
@unlink( $value );
}
}
}
return @rmdir( $folderPath );
} else {
return false;
}
}