Ver Mensaje Individual
  #3 (permalink)  
Antiguo 31/07/2009, 03:03
gorisito
 
Fecha de Ingreso: agosto-2006
Mensajes: 19
Antigüedad: 17 años, 8 meses
Puntos: 0
Respuesta: Formulario HTML con PHP

Hola,

Gracias por la respuesta. Adjunto código:

Código PHP:
<?php
$dia
=date("d.m.Y");
$hora=date("H:i:s"); 

$material1 $_POST["material1"];
$material2 $_POST["material2"];
$material3 $_POST["material3"];
$material4 $_POST["material4"];
$thank="gracias.html";
$sfrom="[email protected]"//cuenta que envia
$sdestinatario="[email protected]"//cuenta destino
$ssubject="subject"//subject
$shtml"
<p>$material1 X $material2</p>
<p>$material3 X $material4</p>
<p>$material5 X $material6</p>
<p>$material7 X $material8</p>
<p>$material9 X $material10</p>
<p>$material11 X $material12<br>
</p>
"
//mensaje
$sheader="From:".$sfrom."\nReply-To:".$sfrom."\n";
$sheader=$sheader."X-Mailer:PHP/".phpversion()."\n";
$sheader=$sheader."Mime-Version: 1.0\n";
$sheader=$sheader."Content-Type: text/html";
mail($sdestinatario,$ssubject,$shtml,$sheader);
Header ("Location: $thank");
?>
Así es como lo tengo, y así funciona perfectamente, pero cuando quiero por ejemplo poner esos materiales en una tabla con <table>, ya no envía el correo. Es más, si uso $shtml='$material1' con las comillas simples, me llega al correo la variable sin transformar, es decir $material1.

Gracias por tu tiempo.