Nov 15, 2014, 5:33 AM
Post #5 of 5
If you want to capture several items, you can do it in a list context, as in this example under the Perl debugger:
Re: [jonjon] Extracting String that is contained in Double Quotes, Single Quotes and there can be Quotes within Quotes
[In reply to]
DB<1> $_ = 'If [Jon is Great] = "01/31/20XX" then "January" '
DB<2> @matches = /"(.*?)"/g;
DB<3> x \@matches;
Having said that, I agree with Bill that the module Regexp::Common qw(balanced) is most probably a better solution.