8791 sujets

Développement web côté serveur, CMS

Bonsoir

J'ai créé un email en html qui marche, je n'arrive pas à faire une region repetee sur <tr> de mon tableau pour afficher les differents articles.
Mes recherches sur internet sont Smiley decu .


if (!function_exists("GetSQLValueString")) {
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "") 
{
  $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;

  $theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);

  switch ($theType) {
    case "text":...
     
$colname_Recordset1 = "-1";
if (isset($_GET['commandeID'])) {
  $colname_Recordset1 = $_GET['commandeID'];
}
mysql_select_db($database_connexion, $connexion);
$query_Recordset1 = sprintf("SELECT listes.reference,  ...", GetSQLValueString($colname_Recordset1, "int"));
$Recordset1 = mysql_query($query_Recordset1, $connexion) or die(mysql_error());$row_Recordset1 = mysql_fetch_assoc($Recordset1);
$totalRows_Recordset1 = mysql_num_rows($Recordset1);


$date = stripslashes(htmlentities($row_Recordset1['date']));
$commandeID = stripslashes(htmlentities($row_Recordset1['ID']));...

$from = "test@live.com";$reply = $from; $to = $email;
$contenu = "<html><body><br />Confirmation ...<br /><br />";
$contenu .= "..vous remercie pour ... ".$date;
$contenu .= 
"<table width=\"400\" border=\"1\" cellpadding=\"0\" cellspacing=\"0\" bordercolor=\"#999999\">
   <tr>
     <td>Article</td>
     <td>Quantité</td>
     <td>Prix</td>
   </tr>
  <?php do { ?>
   <tr>
    <td>$titre</td>
     <td>$quantite</td>
 <td>$prixArticle</td>
   </tr>
 <?php } while ($row_Recordset1 = mysql_fetch_assoc($Recordset1)); ?>	   		    
 </table>";		  	
$headers = 'MIME-Version: 1.0' . "\n"; 
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\n"; 
$headers .= 'From: '.$from."\n"; 
$reply = $headers."Reply-to: ".$reply."\n";
	
$resultat = mail($to, $objet, $contenu, $reply);