http://qs1969.pair.com?node_id=1018690


in reply to Seaching for text in string and comparing to xml, if not found print text

Hack way, regex, proper way, parse the XML.

if ($line =~ m|<ALERT_ID>(\d+)</ALERT_ID>|) { my $alert_id = $1; }

I'll leave the XML solution to you + CPAN + searching...