function MkdirForFile($filename,&$error = null,&$error_str = null){
		$directory = preg_replace('/[^\/]+$/','',$filename);
		if(!strlen($directory)){
			$error = true;
			$error_str = "can't determine directory name";
			return;
		}
		return self::Mkdir($directory,$error,$error_str);
	}
function MkdirForFile($filename,&$error = null,&$error_str = null){
		$directory = preg_replace('/[^\/]+$/','',$filename);
		if(!strlen($directory)){
			$error = true;
			$error_str = "can't determine directory name";
			return;
		}
		return self::Mkdir($directory,$error,$error_str);
	}
function MkdirForFile ( $ filename , & $ error = null , & $ error_str = null ) { $ directory = preg_replace ( '/[^\/]+$/' , '' , $ filename ) ; if ( ! strlen ( $ directory ) ) { $ error = true ; $ error_str = "can't determine directory name" ; return ; } return self :: Mkdir ( $ directory , $ error , $ error_str ) ; }
Created a directory for the given filename.


```
Files::MkdirForFile("/path/to/a/file.dat");
```
Created a directory for the given filename .