in reply to Creating Filenames using variables

Try a little something like this:
$mon =~ s/(.+)(\..+)/$1_`date \+\%m\%d\%Y`\.$2/e;
Update : /e added to end of regex to fix error. (Thanks to EvanK)

Replies are listed 'Best First'.
Re: Re: Creating Filenames using variables
by EvanK (Chaplain) on Feb 09, 2001 at 00:18 UTC
    good idea including the date process in the regex. still forgot the /e regex flag though, and the original post used system, not backquotes

    ______________________________________________
    When I get a little money, I buy books. If I have any left over, I buy food and clothes.
    -Erasmus