If you do the pattern matching in list context with the /g (global) option, you can capture all the matches in one array without using $1. e.g., @matches = $text =~ /(pattern)/g;
In reply to Re: extract substring between token a and token b
by itub
in thread extract substring between token a and token b
by philosophia
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |