in reply to Re: Re: how do I swap 2 strings in a file?
in thread how do I swap 2 strings in a file?
That should be a bit better than matching the whole string, also I added the /m modifier. I put the /s modifier in too because I thought /msg just looked cool : )$string=~s/($string_1)(.*)($string_2)/$3$2$1/msg;
|
|---|