Dear Chas,
 
Thanks so much, The problem fixed now. It has annoyed me for two days.
 
Cheers
 
Org
> Date: Sun, 15 Feb 2009 20:56:51 -0500> Subject: Re: strange string match> 
> From: [email protected]> To: [email protected]> CC: [email protected]> 
> > On Sun, Feb 15, 2009 at 20:32, org chen <[email protected]> wrote:> 
> snip> > while(my $line = <>){ chomp( $line ); print "<p>current line is 
> $line";> > if($line =~ /^[Mon|Tue|Wed|Thu|Wed|Fri|Sat|Sun]/){ #push old data 
> into array print "<p>time: $line"; } elsif($line = ~ /\[DIED\]/){ print 
> "<p>DIED: $line "; } elsif($line =~ /\[SUCCESS\]/){ print "<p> 
> success:$line"; } elsif($line =~ /\[PROCESS\]/){ print "<p>process: $line"; } 
> }> snip> > Wow, I hope your mail client did that to your code. The problem> 
> appears to be the line the contains> > elsif($line = ~ /\[DIED\]/)> > This is 
> assigning the complement of the result of running the regex> against $_ to 
> $line. I doubt that is what you desired. I assume your> meant> > elsif($line 
> =~ /\[DIED\]/)> > -- > Chas. Owens> wonkden.net> The most important skill a 
> programmer can have is the ability to read.
_________________________________________________________________
Get rid of those unwanted christmas presents! Get what you want at ebay. 
http://a.ninemsn.com.au/b.aspx?URL=http%3A%2F%2Frover%2Eebay%2Ecom%2Frover%2F1%2F705%2D10129%2D5668%2D323%2F4%3Fid%3D10&_t=763807330&_r=hotmailTAGLINES&_m=EXT

Reply via email to