Use PHPmailgun to send emails

Source: Internet
Author: User
To improve the mail sending success rate, we can use third-party services to implement the mail sending function. A typical provider is mailgun outside China and sendcloud in China, as the sendcloud template is limited to 30, and each template modification must be reviewed, you can only discard sendcloud. After mailgun is bound to a credit card

To improve the mail sending success rate, we can use third-party services to implement the mail sending function. A typical provider is mailgun outside China and sendcloud in China, as the sendcloud template is limited to 30, and each template modification must be reviewed, you can only discard sendcloud. After mailgun is bound to a credit card

To improve the mail sending success rate, we can use third-party services to implement the mail sending function. A typical provider is mailgun outside China and sendcloud in China, as the sendcloud template is limited to 30, and each template modification must be reviewed, you can only discard sendcloud.

After mailgun is bound to a credit card, 10 thousand emails will be given each month. This is basically enough for small sites, and the excess is not expensive.

Some may consider that sendcloud is faster in China and mailgun is slower in foreign countries. In fact, if you want to receive emails from other countries, how can you send them slowly.

Send email via mailgun API
# Include the Autoloader (see "Libraries" for install instructions) require 'vendor/autoload. php'; use Mailgun \ Mailgun; # Instantiate the client. $ mgClient = new Mailgun ('key-3ax6xnjp29jd6fds4gc373sgvjxteol0'); $ domain = "samples.mailgun.org"; # Make the call to the client. $ result = $ mgClient-> sendMessage ($ domain, array ('from' => 'excited user', 'to' => 'baz ', 'subobject' => 'mail title', 'text' => 'mail content ',));

This API looks similar to the REST WebService API, which is simple and fast.

(...)
Read the rest of emails sent using PHP mailgun (105 words)

©Li Xi for lixphp, 2014. | Permalink | No comment | Add todel. icio. us
Post tags: API, mailgun, sendmail, SMTP

Feed enhanced by Better Feed from Ozh

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.