use CGI qw( escapeHTML ); use URI::Escape qw( uri_escape ); foreach my $line (@results) { my ($first, $second, $third) = split(/::/, $line); my $ue_first = uri_escape($first); my $ue_second = uri_escape($second); my $ue_third = uri_escape($third); my $he_first = escapeHTML($first); my $he_third = escapeHTML($third); print qq($he_first $he_third
); }