Posted by Mel on 07/11/06 15:03
On 2006-07-10 03:49:12 +1000, "André Hänsel" <andre@webkr.de> said:
> ImOk schrieb:
>> is_dir ("./mysubdir/mysubsubdir" )
>
> That only determines if ./mysubdir/mysubsubdir is a directory. It makes
> no statement about whether it is a subdirectory of another directory.
>
> is_dir('../../nosubdir) will return true (if the dir exits, of course),
> although it is no subdir of the working dir.
Wouldn't you just try to open it as a directory from the context of the
parent and if it opens, then it's a subdir?
[Back to original message]
|