Jump to content

send email, to dinamic addressee


tac

Recommended Posts

can help with the code to do this:

 

I have a form with the following fields:

 

form in detail:

 

first part: NAME1, PHONE, ID, EMAIL

 

second part:

 

NAME2, EMAIL2

 

NAME3, EMAIL3

 

NAME4, EMAIL4

 

NAME5, EMAIL5

 

NAME6, EMAIL6

 

to first part i used "foreach" to send all data colect to mi email (in html)

 

I want to send emails, the emails entered EMAILx fields, including the following phrase, "NAMEx, we recommend NAME1" in subject.

to each of other name at your emails

 

this is my code for the first part

 

 

<?
$mensaje = "";
foreach ($_POST as $llave=>$dato) {
if ($llave != "Submit")
	$mensaje .= "$llave: $dato\n";
}
//$to="[email protected]";
$to="[email protected]";
$subject="INSCRIPCION SORTEO ANCEL";

mail($to,$subject,$mensaje,"From: La Fiesta Inolvidable<No Replay>");

?><title>La Fiesta Inolvidable</title>
<style type="text/css">
<!--
body {
background-color: #000000;
background-image: url();
}
.Estilo1 {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 12px;
color: #CCCCCC;
}
.Estilo15 {font-size: 10px; color: #CCCCCC; }
.Estilo16 {color: #FF0000}
.Estilo17 {	font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 12px;
font-weight: bold;
color: #CCCCCC;
}
.Estilo17 {	font-size: 12px;
color: #CCCCCC;
font-weight: bold;
}
-->
</style></head>

<body>
<meta name="keywords" content="nostalgia,sorteo,gratis">

</body>
</html>

 

 

Thz for any help

Link to comment
https://forums.phpfreaks.com/topic/211500-send-email-to-dinamic-addressee/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.