我写下面的代码在执行时遇到错误。
<?php
$to = "somebody@example.com";
$subject = "My subject";
$txt = "Hello world!";
$headers = "From: webmaster@example.com" . "\r\n" .
"CC: somebodyelse@example.com";
$retval = mail($to,$subject,$txt,$headers);
if( $retval == true ) {
echo "Message sent successfully...";
}else {
echo "Message could not be sent...";
}
?>
网址:http://www.casaplaya.co.za/test-email.php
无法发送消息... PHP警告: 邮件(E:\ IIS \ LogFiles \ PHP \ php53mail.log):无法打开流: F:\ domains \ casaplaya.co.za \ wwwroot \ test-email.php中的权限被拒绝 第18行PHP警告:mail():SMTP服务器响应:550没有这样的用户 这里是第18行的F:\ domains \ casaplaya.co.za \ wwwroot \ test-email.php
我无法弄清楚这个问题。如果有人帮我找出解决方案,那就太好了。
提前致谢。