in reply to Re: Can you teach a new dog an old trick?
in thread Can you teach a new dog an old trick?

You want to use File::Find to deal with that.

use strict; use File::Find; find( sub { return unless -f $_ and /\.html?$/; # do your funky thang }, shift || '.' );

That is, recurse starting from the directory given on the command line, or the current directory if nothing is specified. Then, only for directory entries that are files whose extension is .htm or .html, do whatever makes you happy.

--
g r i n d e r