rhoadesjn has asked for the wisdom of the Perl Monks concerning the following question:
#Open the directory opendir (DIR, "http://yoda/Documents/PSG/Customers/") || die ("Unable +to open directory"); #Read list of files in the directory while ($filename = readdir(DIR)) { @files = readdir(DIR); } closedir(DIR); #Remove the file . which represents the current directory shift (@files); #Go through each of the files in the directory foreach $file (@files) { #Open subfolder open (DIR, "http://yoda/Documents/PSG/Customers/$file/Support/sitema +p/") #code here copies each document from subfolder to c:\sitemaps }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Opening a web page directory
by brian_d_foy (Abbot) on Apr 12, 2005 at 22:12 UTC | |
Re: Opening a web page directory
by elwarren (Priest) on Apr 12, 2005 at 23:17 UTC | |
by rhoadesjn (Novice) on Apr 13, 2005 at 14:21 UTC | |
Re: Opening a web page directory
by moot (Chaplain) on Apr 12, 2005 at 21:15 UTC | |
Re: Opening a web page directory
by halley (Prior) on Apr 12, 2005 at 21:21 UTC | |
Re: Opening a web page directory
by ww (Archbishop) on Apr 12, 2005 at 22:06 UTC | |
Re: Opening a web page directory
by sh1tn (Priest) on Apr 12, 2005 at 21:35 UTC |