Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: Opening a Directory

by FoxtrotUniform (Prior)
on Jan 19, 2002 at 01:48 UTC ( #139961=note: print w/replies, xml ) Need Help??


in reply to Opening a Directory

Can you show me how to validate the existence of a directory?

You want the file test operators, specifically -d.

If the directory name has a space in between, what should I do?

Nothing special, as long as you have the whole dir name instead of just the first word.

And how to capture all the files under a directory?

opendir, readdir, closedir.

And God bless all Monks!

Which one?

--
:wq

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://139961]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (6)
As of 2021-04-13 22:00 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?