Depends on what you are really doing. If only one level, then opendir and readdir would be one way. If there are other folders and you need to go down them, then File::Find would probably be a good way to go. Wags ;) -----Original Message----- From: Tim Booher [mailto:[EMAIL PROTECTED]] Sent: Thursday, November 21, 2002 15:20 To: [EMAIL PROTECTED] Subject: should be a simple traverse and print
Hello - I am looking for ideas to traverse a directory structure and print all jpg files in the directory along with their parent directory. For example if I have Folder1 with 1.jpg 2.jpg 3.jpg Folder2 with A.jpg B.jpg C.htm By running test.pl in Folder1 and Folder2's parent directory I would get: Folder 1 : 1.jpg Folder 1 : 2.jpg Folder 2 : A.jpg Folder 2 : B.jpg I have a feeling that perl can do this very simply, but I am still new to the language . . . any ideas? Tim ********************************************************** This message contains information that is confidential and proprietary to FedEx Freight or its affiliates. It is intended only for the recipient named and for the express purpose(s) described therein. Any other use is prohibited. ****************************************************************