Does it have something to do with scalar vs list data?
Indeed it does. In scalar context (my $var =) a match regex returns true or false. In list context (my ($var) =) a match regex returns the list of captures. You are interested in just the contents of the first capture so:
my ($var) = $page =~ /...(...).../;
is the appropriate syntax.
Update: provide complete code line to illustrate appropriate list context usage.
In reply to Re^3: Improve My Code...
by GrandFather
in thread Improve My Code...
by cheech
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |