Hi,
How can I replace the literal "nlf" with a variable in the code below?
Thanks in advance.
sub parseLogLine {
$line = $_;
%searchInfo = ();
@searchInfo = split / +/, $line;
# found any listings?
$numListings = $searchInfo[8];
$numCategories = $searchInfo[10];
# did I detect any errors or exceptions
($err) = ( $line =~ / ERR (\w+) /i );
if ( $err ne "") {
$err =~ tr/A-Z/a-z/;
if ($err eq "nlf") {
$NLFerr++;
}
elsif ($err eq "cat") {
$CATerr++;
}
}
-Larry
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]