One thing to add: it should be possible to use a relative pathname, but that would be 'myDir', not '/myDir'. Starting a pathname with a slash makes it an absolute pathname, so it looks for myDir in the root filesystem (whatever that means on Windows; maybe C:\myDir?). A relative pathname is looked for inside your current working directory, so if your CGI runs from C:/www/htdocs, then passing 'myDir' to find() should cause it to look in C:/www/htdocs/myDir.
If that doesn't work, you'll need to figure out in what current working directory your CGI does run. Or use chdir to switch to the right directory before calling find(). Or use the absolute pathname, as Corion pointed out and you've already discovered works fine.
Aaron B.
Available for small or large Perl jobs; see my home node.
|