Page 1 sur 1

recuperer une liste pour un mail

Posté : 08 nov. 2005, 17:44
par Gico
Bonjour

Je voudrais envoyer un mail qui comporterais une liste d'elements selectionné dans une table. Je sais recuperer ses elements pour affichage:

Code : Tout sélectionner

<?php do { ?> <tr> <th scope="row"><span><?php echo $row_rsArticles['marque']; ?></span><span>&nbsp;<?php echo $row_rsArticles['reference']; ?></span></th> <td ><div> <span><?php echo $row_rsArticles['quantite']; ?></span> </div></td> <td ><div><span ><?php echo $row_rsArticles['prixArticle']; ?></span> <span >€</span></div></td> <td><?php echo $row_rsArticles['total']; ?> €</td> </tr> <?php } while ($row_rsArticles = mysql_fetch_assoc($rsArticles)); ?> [quote] Mais comment s'y prendre pour entrer ce resultat (formaté avec des retours a la ligne dans un corp de mail du style: $to = '[email protected]'; $subject = ; $message = ; $headers = ; mail($to, $subject, $message, $headers); merci[/quote]

Posté : 08 nov. 2005, 21:55
par the_grinch
slt alors voila :

$subject = ;
$message = .$row_rsArticles['marque']. .$row_rsArticles['reference']. ;
$headers = ;
mail($to, $subject, $message, $headers);

Je pense que c'est comme ça ou un truc comme ça !
toi tu as fait ça automatiquement avec dreamweaver ! je me trompe ?

Posté : 10 nov. 2005, 20:09
par Gico
oui avec dreamweaver, je vais étudier ton code merci