mmittiga17 has asked for the wisdom of the Perl Monks concerning the following question:
Hi All,
I am trying to get the number into $acct that follows "Account number" in a string. This should work but it is not, what am I doing wrong? Thanks!
$page2 = "Account number 12345678"; if ( $page2 =~ m/Account number (.*?)/g ) { $acct = $1; print "acct = $acct\n"; }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Regex Question in Perl
by ikegami (Patriarch) on Dec 22, 2010 at 18:29 UTC | |
Re: Regex Question in Perl
by toolic (Bishop) on Dec 22, 2010 at 18:34 UTC | |
Re: Regex Question in Perl
by AR (Friar) on Dec 22, 2010 at 18:33 UTC | |
by AnomalousMonk (Archbishop) on Dec 22, 2010 at 18:49 UTC | |
by ikegami (Patriarch) on Dec 22, 2010 at 18:37 UTC |
Back to
Seekers of Perl Wisdom