Mail function use error excluding __ function

Source: Internet
Author: User
Tags win32

Yesterday learned PHP mail function
To do a user feedback and then send comments to the Webmaster's page
But after submission, returned an error
Warning:mail () [Function.mail]: SMTP Server response:550 5.7.1
Unable to relay for wsq239@163.com in  
d:/mydocument/php/jh/admin/ sendfeedback.php on line
This bug really gave me a headache for a while
I later learned that the mail function in PHP is using an SMTP protocol that comes with the system to send mail
in my machine (Win XP pro+ Apache+php+mysql) After installing IIS,
has a default SMTP virtual server in it
before using it, we need to make some changes in the PHP configuration file
Find the following section, and then make changes according to your situation
[mail Function]
; For Win32.
SMTP = localhost
Smtp_port =

; For Win32.
Sendmail_from = cocowool@msn.com
And then there is a Linux how to set up the
but I do not understand Linux, so there is no tube, hehe
If you do not set the Sendmai_from, The system prompts you that the
Mail function is also not sufficient
Warning:mail () [Function.mail]: "Sendmail_from" not set in php.ini or custom "from:" Heade R missing in
d:/mydocument/php/jh/admin/sendfeedback.php on line
PHP.ini, I found that there was still the first question. I heard that use SMTP to have permission, is not my current computer user does not have permissions
I think it should not, because only I have a user on the computer
regardless of the first change the
Virtual Server-> Property-> Access-> access control-> authentication
Remove the check boxes before Basic authentication and Integrated Windows authentication
only anonymous validation
But the problem is still unable to relay
Baidu, which is said to be a relay problem
then follow the instructions
Virtual server-> Property-> Access-> relay
Select that check box and then add the 127.0.0.1 Local address
test, OK
problem solved
But still not very clear for SMTP
And the idea of setting up a local mail test environment was not implemented
because now you can only send mail, but not the ability to receive mail
Baidu, and found that imail may be a good tool
of course there are many such as iwebmail,qmail and so on , the phase of the IMAIL
specific configuration has not been made
and so on to write a text to

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.