'webmaster@example.com', 'Sales' => 'sales@example.com'); if (isset($_POST['submitButton'])) { $headers = 'MIME-Version: 1.0' . "\r\n"; $headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n"; $headers .= 'From: No-reply ' . "\r\n"; $headers .= 'X-Mailer: PHP/' . phpversion(); $parameters = '-fnoreply@clarkson.edu'; $subject = 'Your web mailer'; $message = '
' . print_r($_POST, true) . '
'; $status = mail($to[$_POST['to']], $subject, $message, $headers, $parameters); if($status) { $output = 'Your email has been sent!'; } else { $output = 'ERROR'; } } $to_field = ''; ?>