PHP rmdir


the rmdir() function used to delete a directory, returns TRUE if successful, and FALSE otherwise.

grammar:

bool rmdir(string dirname)

example:

$dirname = 'testdir';
if (rmdir($dirname)) {
     echo "directory $dirname deleted successfully";
} else {
     echo "directory $dirname delete failed";
}



Copyright 2014-2017 by DeveloperTut.com. All Rights Reserved.
TwitterGoogle+Facebook