in reply to positional variable question

You're missing the backslash before the "d" in your regex:
\d{4}
This regex does what you want, I think:
$date_cfg =~ s!^(\d{4})/(\d{2})(\d{2})$!$2/$3/$1!;
There may be a better way, but this works for me.

Replies are listed 'Best First'.
RE: Re: positional variable question
by Limo (Scribe) on Aug 27, 2000 at 06:31 UTC
    In addition to the typo, "(\d{4}", that's what I was missing! Splitting the string into 2 variables and substituting them into 3! Thanks!