Re: Regexp - alternate match and grouping
- From: "Paul Lalli" <mritty@xxxxxxxxx>
- Date: 28 Feb 2006 05:33:58 -0800
Paul Lalli wrote:
Witold Rugowski wrote:
Feb 28 00:00:00 HOSTNAME Feb 28 2006 01:00:00 HOSTNAME : %PIX-6-305011 [cut]
WTsyslog[2006-02-26 23:59:59 ip=IP_ADDRESS pri=6] <14>Feb 26 2006 23:59:59: %PIX-6-302016: [cut]
my $date_pat = qr/[a-z]{3} \d{2} \d{2}:\d{2}:\d{2}/;
Should have the /i modifier there.
my ($host_or_ip, $date);
if (/^([\w.-]+) ($date_pat)/){
Should not have the ^ anchor there.
Apologies for those errors.
Paul Lalli
.
- References:
- Regexp - alternate match and grouping
- From: Witold Rugowski
- Re: Regexp - alternate match and grouping
- From: Paul Lalli
- Regexp - alternate match and grouping
- Prev by Date: Re: Regexp - alternate match and grouping
- Next by Date: Re: Regexp - alternate match and grouping
- Previous by thread: Re: Regexp - alternate match and grouping
- Next by thread: pruning directories by adding hard links
- Index(es):
Relevant Pages
|
|