Forum |  HardWare.fr | News | Articles | PC | S'identifier | S'inscrire | Shop Recherche
1143 connectés 

  FORUM HardWare.fr
  Programmation
  PHP

  [PHP] mail()

 


 Mot :   Pseudo :  
 
Bas de page
Auteur Sujet :

[PHP] mail()

n°160786
vektorDire​ct
bouge pas, meurs, ressucite !
Posté le 17-06-2002 à 14:25:11  profilanswer
 

:hello:  
 
comment envoyer un mail en format HTML avec mail() ?
 
si vous avez des explications ou des liens... passke là... je nage...

mood
Publicité
Posté le 17-06-2002 à 14:25:11  profilanswer
 

n°160794
skylight
Made in France.
Posté le 17-06-2002 à 14:28:23  profilanswer
 

$to  = "Mary <regrgr@trancarea.com>" ; //note the comma
 
 
subject
$subject = "Birthday Reminders for August";
 
message
$message = '
<html>
<head>
 <title>Birthday Reminders for August</title>
</head>
<body>
<p>Here are the birthdays upcoming in August!</p>
<table>
 <tr>
  <th>Person</th><th>Day</th><th>Month</th><th>Year</th>
 </tr>
 <tr>
  <td>Joe</td><td>3rd</td><td>August</td><td>1970</td>
 </tr>
 <tr>
  <td>Sally</td><td>17th</td><td>August</td><td>1973</td>
 </tr>
</table>
</body>
</html>
';
 
 To send HTML mail, you can set the Content-type header.
$headers  = "MIME-Version: 1.0\r\n";
$headers .= "Content-type: text/html; charset=iso-8859-1\r\n";
 
 additional headers
$headers .= "From: Birthday Reminder <birthday@example.com>\r\n";
 
$headers .= "Cc: birthdayarchive@example.com\r\n";
$headers .= "Bcc: birthdaycheck@example.com\r\n";
 
 and now mail it
mail($to, $subject, $message, $headers);


Message édité par skylight le 17-06-2002 à 14:28:45
n°160796
peemousse
Posté le 17-06-2002 à 14:29:43  profilanswer
 
n°160808
vektorDire​ct
bouge pas, meurs, ressucite !
Posté le 17-06-2002 à 14:37:54  profilanswer
 

ok merçi
mais bon, je comprends pas, j'ai fais plusieurs scripts dans le même genre, mais ça marche pô.

n°160894
vektorDire​ct
bouge pas, meurs, ressucite !
Posté le 17-06-2002 à 15:18:05  profilanswer
 

http://www.zend.com/zend/spotlight [...] p#Heading5
 
g trouvé, tout est expliqué içi.


Aller à :
Ajouter une réponse
  FORUM HardWare.fr
  Programmation
  PHP

  [PHP] mail()

 

Sujets relatifs
[PHP] Formulaire --> Mail --> Inscriptionfonction mail() en PHP
[PHP] Test de la fonction mail() en local ?Script PHP Form2Mail utilisant ()mail et gérant les fichiers joints ?
[PHP] mail bomber ...[pHp] envoi massif de mail
[ Php ] mail() et serveur appache localMail en PHP via Intranet
[PHP] variable predefinie $_POST['ma_variable'] et fonction mail()[PHP] Mail : accusé de lecture ?
Plus de sujets relatifs à : [PHP] mail()


Copyright © 1997-2022 Hardware.fr SARL (Signaler un contenu illicite / Données personnelles) / Groupe LDLC / Shop HFR