Why does the enterprise post office account verification fail when sending an email in PHP?

Source: Internet
Author: User
Tags mail code

I wrote a PHP e-mail code a few days ago and passed the 126 mail sending test. Later, the customer bought the enterprise post office and Netease,

I think this is not a problem with my code. Therefore, I Went To Netease's enterprise Post Office Management page to find the cause. Indeed, it was a domain name MX DNS resolution error, after configuring according to the above steps, try again the next day...

This is the first two big ones. It's too nonsense. Let's go straight to the question.

 

During this period, a bunch of debugging and repetition were conducted .. Repetition...

 

At last, I used telnet to verify the enterprise post office. I found that the enterprise post office account must use your own domain name as an account, while ordinary accounts do not need a suffix, for example, when the abc@126.com verification we will ABC base64 computation sent to the mail server for verification, and enterprise post office account for the abc@youname.com then you have to use the abc@youname.com for base64 computation sent to the mail server, on, the problem is here, Khan. This is because the code intercepts the part of the account @ and uses it as the login account. Then, you only need to remove this part and it will be OK.

 

When writing a mail class, the constructor can add a parameter, that is, whether the enterprise Post Office is used, which is more flexible to handle. Haha --~!~

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.