in reply to Match Text with Single Quotes
use warnings; use strict; my $customTextinPrePostScript = q(MyName='Custom'); while (my $line = <DATA>) { if ($line =~ /$customTextinPrePostScript/i) { print $line; } } __DATA__ hello MyName='Custom' foo nothing
|
|---|