mkdir('my_directory');
mkdir('my_directory', 0777);
mkdir('parent_directory/child_directory', 0777, true);This will create a new directory named "parent_directory" in the current working directory, and then create a nested directory named "child_directory" within it, with permissions set to 0777. The "true" parameter tells the mkdir function to create the parent directory(s) recursively. Package library: The mkdir function is a built-in function of the PHP programming language, so no external package library is required.