- push @out, $self->msg('e3', 'show/qrz', uc $l);
+ Log('call', "$call: show/qrz \U$body");
+ my $state = "blank";
+ foreach my $result (split /\r?\n/, $body) {
+ dbg("qrz: $result") if isdbg('qrz') && $result;
+ if ($state eq 'blank' && $result =~ /^<Callsign>/i) {
+ $state = 'go';
+ } elsif ($state eq 'go') {
+ next if $result =~ m|<user>|;
+ next if $result =~ m|<u_views>|;
+ next if $result =~ m|<locref>|;
+ next if $result =~ m|<ccode>|;
+ next if $result =~ m|<dxcc>|;
+ last if $result =~ m|</Callsign>|;
+ my ($tag, $data) = $result =~ m|^\s*<(\w+)>(.*)</|;
+ push @out, sprintf "%10s: $data", $tag;
+ }
+ }
+ if (@out) {
+ unshift @out, $self->msg('http2', "show/qrz \U$l");
+ } else {
+ push @out, $self->msg('e3', 'show/qrz', uc $l);
+ }