$receiver="me@mysite.com";
$subject="Feedback";
$header="MIME-Version: 1.0\r\nContent-type: text/plain; charset=iso-8859-1\r\n";
//'add every form element and its value to the email
$body="";
foreach (array_keys($_POST) as $el)
{
if (strcmp("subject",strtolower($el))==0) $subject=$subject." -- ".$_POST[$el];
$value=$_POST[$el];
$display="";
if (is_array($value))
{
foreach ($value as $everydisplay)
{
$display.=$everydisplay." ";
}
}
else
{
$display=$value;
}
$body=$body. $el . ": " . $display . "\r\n";
}
//mail($receiver,$subject,$body);
if ($body!="") mail($receiver,$subject,$body,$header);
?>