I want to send an email where the reactants are
the user enters their name ($name)
enters their email ($email)
the people they want to send to (seperated by a single comma): ($recipient)
their personal message ($message)
<?
$subject = "$name recommends you to visit mysite";
$message = "$name recommends you to visit my site blablabla
---This is an automated response, please do not reply!---";
$display = explode (",", $recipient);
$streturn = array($display);
for ($i=0; $i<$display; $i++) {
$streturn[$i];
}
return $streturn;
$mailheaders = "From: $email from * <$email> \n";
$mailheaders .= "Reply-To: $email\n";
$to = $streturn;
mail($to, $subject, $message, $mailheaders);
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body>
<table width="75%" border="0" align="center">
<tr>
<td><div align="center">
<p>Thank you for submitting e-mail using <strong><em><font color="#FF0000" face="Georgia, Times New Roman, Times, serif">e</font></em></strong>-oped.com</p>
<p>Your message has been submitted to your friend(s). <br>
<a href="javascript:history.go(-2);">Go back to where you were.</a></p>
<p><? echo"$to"; ?></p><div align="center">
These are the following people that will recieve your
e-mail in a few minutes:</div><div align="left"><br>
<? echo "$display[0]"; ?><br>
<? echo "$display[1]"; ?> <br>
<? echo "$display[2]"; ?> <br>
<? echo "$display[3]"; ?> <br>
<? echo "$display[4]"; ?> <br>
<? echo "$display[5]"; ?> <br> </div>
</div></td>
</tr>
</table>
</body>
</html>