William M West wrote: > > David Dorward wrote: > > > >(my $action) = ($html =~ /action=\"(.*?)\"/); > > > >That gives the same as my example. > > using parentheses to capture matches is really neat :) i > did not know that you could do that.
It is not the parentheses per se that capture matches, it is the list context that the parentheses provide. my ( $action ) = $html =~ /action="(.*?)"/; my @actions = $html =~ /action="(.*?)"/; print $html =~ /action="(.*?)"/; All these examples provide list context to the expression $html =~ /action="(.*?)"/ but only the first one _requires_ parentheses. John -- use Perl; program fulfillment -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>