开启了IIS中的默认smtp虚拟服务器, 并在php.ini中作相应设置: [mail function] ; For Win32 only. SMTP = localhsot; For Win32 only. sendmail_from = [email protected]程序如下: <?php mail("[email protected]", "the subject", "hello", "From: [email protected]\r\n" ."Reply-To:[email protected]\r\n" ."X-Mailer: PHP/".phpversion()); ?>出错信息: Warning: mail() [function.mail]: Failed to connect to mailserver at "localhsot" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in F:\root\flower\mailone.php on line 5连接邮件服务器失败,我该怎么办?????????
改变php.ini中作相应设置: [mail function] ; For Win32 only. SMTP = 192.168.1.3; For Win32 only. sendmail_from = [email protected]保存设置,重起apache程序如下: <?php mail("[email protected]", "the subject", "hello", "From: [email protected]\r\n" ."Reply-To:[email protected]\r\n" ."X-Mailer: PHP/".phpversion()); ?>出错信息:Warning: mail() [function.mail]: SMTP server response: 550 5.7.1 Unable to relay for [email protected] in F:\root\flower\mailone.php on line 5到这一步,smtp服务器有响应,但是发送不成功。 高手能指点以下吗?????????????
不能用iis自带的smtp,把这个卸载,然后装个imail,就可以了~~我就是这样发信的。
我下载了webeasymail邮件服务器,可以在outlook express里面收外部internet邮件, 但是在php中用mail()还是不成功: <? mail("[email protected]","邮件主题","正文内容this is from php","from:[email protected]"); ?> Warning: mail() [function.mail]: SMTP server response: 550 Local user only or Authentication mechanism in F:\phpweb\test.php on line 2那位高手指点一下,谢谢 !!!!!!!!!
总结一下: 1。php.ini中smtp=localhost(就是默认啦) 2。装一个smtp服务器。我是了两个:Imail Server 和Webeasymail。后者比较小巧简易,推荐像我这样的初学者使用。 3。对外发信的话,一定要设置有效的DNS服务器名。哪位还有补充吗?
我好像从来没装过什么smtp服务程序;如果不是win2000自带的那恐怕是没有了。那怎么安装呢?哪里有down?
但是即使安装完配置好后在本机上可以发送也只是在本机上可以而已。
大部分提供软件下载的网站都有.
然后呢?
并在php.ini中作相应设置:
[mail function]
; For Win32 only.
SMTP = localhsot; For Win32 only.
sendmail_from = [email protected]程序如下:
<?php
mail("[email protected]", "the subject", "hello",
"From: [email protected]\r\n"
."Reply-To:[email protected]\r\n"
."X-Mailer: PHP/".phpversion());
?>出错信息:
Warning: mail() [function.mail]: Failed to connect to mailserver at "localhsot" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in F:\root\flower\mailone.php on line 5连接邮件服务器失败,我该怎么办?????????
[mail function]
; For Win32 only.
SMTP = 192.168.1.3; For Win32 only.
sendmail_from = [email protected]保存设置,重起apache程序如下:
<?php
mail("[email protected]", "the subject", "hello",
"From: [email protected]\r\n"
."Reply-To:[email protected]\r\n"
."X-Mailer: PHP/".phpversion());
?>出错信息:Warning: mail() [function.mail]: SMTP server response: 550 5.7.1 Unable to relay for [email protected] in F:\root\flower\mailone.php on line 5到这一步,smtp服务器有响应,但是发送不成功。
高手能指点以下吗?????????????
我下载了webeasymail邮件服务器,可以在outlook express里面收外部internet邮件,
但是在php中用mail()还是不成功:
<?
mail("[email protected]","邮件主题","正文内容this is from php","from:[email protected]");
?>
Warning: mail() [function.mail]: SMTP server response: 550 Local user only or Authentication mechanism in F:\phpweb\test.php on line 2那位高手指点一下,谢谢
!!!!!!!!!
1。php.ini中smtp=localhost(就是默认啦)
2。装一个smtp服务器。我是了两个:Imail Server 和Webeasymail。后者比较小巧简易,推荐像我这样的初学者使用。
3。对外发信的话,一定要设置有效的DNS服务器名。哪位还有补充吗?