Your value for $OldVer contains regular expression meta characters, like "." (which usually matches any character. See perlre for \Q...\E or quotemeta for how to make sure your value gets interpreted as value instead of a regular expression. You also want to make sure to replace more than just one version occurrence per line, I guess:
s/$OldVer/$NewVer/g;
In reply to Re: Search/Replace action using "."
by Corion
in thread Search/Replace action using "."
by rsperl
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |