<?php
// multiple recipients
$to = '[email protected]' . ', '; // note the comma
$to .= '[email protected]';// 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, the Content-type header must be set
$headers = 'MIME-Version: 1.0' . "\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";// Additional headers
$headers .= 'To: Mary <[email protected]>, Kelly <[email protected]>' . "\r\n";
$headers .= 'From: Birthday Reminder <[email protected]>' . "\r\n";
$headers .= 'Cc: [email protected]' . "\r\n";
$headers .= 'Bcc: [email protected]' . "\r\n";// Mail it
mail($to, $subject, $message, $headers);
?>
手册里有的啊。
// multiple recipients
$to = '[email protected]' . ', '; // note the comma
$to .= '[email protected]';// 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, the Content-type header must be set
$headers = 'MIME-Version: 1.0' . "\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";// Additional headers
$headers .= 'To: Mary <[email protected]>, Kelly <[email protected]>' . "\r\n";
$headers .= 'From: Birthday Reminder <[email protected]>' . "\r\n";
$headers .= 'Cc: [email protected]' . "\r\n";
$headers .= 'Bcc: [email protected]' . "\r\n";// Mail it
mail($to, $subject, $message, $headers);
?>
手册里有的啊。
解决方案 »
- mysql语句,如何去除指定字段的整行
- 关于php中cookies和session的应用
- 怎么我用PHP调用.net 的webservice参数传不过去。参数为空
- 如何在function里操作pdo呀
- 没分了没有办法,在apache下调试php程序出现找不到该页
- 能否在session中注册类?
- 谁有php_mysql.dll文件?
- apache+php问题 不知道是没有高手还是没给分的原因 至今没几人访问,也没能解决
- 哪位高人帮忙把以此JAVA程序改成PHP,谢谢!
- HPH要自学的话,应该从哪里开始学?
- 男儿膝下有黄金,恕在下不能跪求,急需对ibf论坛有研究的大侠们帮助,ibf论坛是否也有bug?
- 关于PHP画面显示的问题。
如果用一般的邮箱,如果用企业邮箱,如果用outlook接收,你能保证收到的邮件的格式吗?
我确实是不会,我发过去经常收到的是带<br> <br/>等的,有的还不分行,随便从手册上考一段就去对付别人的问题..............有点草率吧