#!/usr/bin/perl use CGI qw/:standard/; $| = 1; foreach my $field (param) { foreach my $value (param($field)) { $name .= "Names here\:\t$value"; } } # Mailer section removed from OP's code for testing print header, < $name
$name