Hallo ik ben begonnen om een script te maken om een nieuwsbrief te versturen in html formaat, met onderstaand script werkt alles opzich prima, ik ontvang de mailtjes in Outlook prima in html-formaat, alleen probeer ik ook naar mijn hotmail te sturen en die komt niet aan, weet iemand hoe dit kan?
Dit is een standaard voorbeeld script, die ik in de CHM documentatie van PHP heb.
PHP:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
| <?php /* recipients */ $to = "r3023@msn.com" . ", " ; // note the comma $to .= "raymond@bitsandbrains.nl"; /* subject */ $subject = "Reminders test platform"; /* message */ $message = ' <html> <head> <title>HTML Newsletter</title> </head> <body> Html Newsletter </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 .= "To: Mary <r3023@msn.com>, Kelly <raymond@bitsandbrains.nl>\r\n"; $headers .= "From: Birthday Reminder <ray@bitsandbrains.nl>\r\n"; $headers .= "Cc: Cc@bitsandbrains.nl\r\n"; $headers .= "Bcc: Bcc@bitsandbrains.nl\r\n"; /* and now mail it */ mail($to, $subject, $message, $headers); ?> |
Dit is een standaard voorbeeld script, die ik in de CHM documentatie van PHP heb.