Ver Mensaje Individual
  #3 (permalink)  
Antiguo 09/07/2003, 22:19
Avatar de Gerald
Gerald
 
Fecha de Ingreso: julio-2003
Mensajes: 1.356
Antigüedad: 20 años, 9 meses
Puntos: 2
Lo encontre o no

<HTML><BODY BGCOLOR=FFFFFF>
<?php
$to = '[email protected]';
$from = '[email protected]';

//Check if we have something POSTed by the form.
if (isset($HTTP_POST_VARS)){
//Start with an empty body for the mail message
$body = '';
//Iterate through all the POSTed variables, and add them to the message body.
while (list($key, $value) = each($HTTP_POST_VARS)){
$body .= $key . ' = ' . $value . "
";
}
//Build up some nice From/Reply Headers
$headers = "From: $from
";
$headers .= "Reply-To: $from
";
//Mail the message out.
//Requires setting php3.ini sendmail path as per instructions
$success = mail($to, "Posted " . date("m/d/Y"), $body, $headers);
//Always check return codes from functions.
if ($success){
echo "<B><CENTER>Thank you for your input</CENTER></B>
";
}
else{
echo "<CENTER><B>Internal Error</B>: Your input was unprocessed.<BR>Contact $from</CENTER>
";
}
}
?>
<FORM ACTION=formmail.php METHOD=POST>
<INPUT NAME=sample><BR>
<INPUT TYPE=SUBMIT>
</FORM>
</BODY></HTML>
__________________
Solo por Hoy: Trataré de fortalecer mi mente. Estudiaré y aprenderé algo útil
Hoteldipity
Arte Caracol