The function in PHP that’s used to create a directory is just the same with that in Linux bash shell: mkdir.
First make sure the current working directory is where you want the new directory to be, then run this line of PHP:
mkdir('new_dir'); // creates a new directory named new_dir under the current directory
Pingback: PHP: Change Current Working Directory