create folder php
snippet in php

create folder php

user1099

// Create folder if not exist
		$folderName = 'images/gallery';
		$config['upload_path'] = $folderName;
		if(!is_dir($folderName))
		{
			mkdir($folderName, 0777);
		}

php mkdir

user6188

// Create a directory with the permission level (optional)
<?php
mkdir("/path/to/my/dir", 0700);
?>