Re: [PHP] pathname

2002-03-17 Thread mnc
On Mon, 18 Mar 2002, jtjohnston wrote: > I need a function to traverse a pathname > to check if the path exists, if not start from scratch > and create (MkDir) the path. > > Let's say: > > $to_path = "c:\\aaa\\bbb\\ccc\\ddd\\"; > or > $to_path = "c:/aaa/bbb/ccc/ddd/"; > > if(!is_dir($to_path))

[PHP] pathname

2002-03-17 Thread jtjohnston
I need a function to traverse a pathname to check if the path exists, if not start from scratch and create (MkDir) the path. Let's say: $to_path = "c:\\aaa\\bbb\\ccc\\ddd\\"; or $to_path = "c:/aaa/bbb/ccc/ddd/"; if(!is_dir($to_path)) { #I need to explode by both \\ AND / to find out mkdir($to_p