Menu icon
RedCrackle
Menu icon
Services
01Design Transformation
About UsCase StudiesBlogContact Us

<

Blog post

How to send HTML emails via SMTP server using HTML Mail and SMTP modules

Neerav Mehta

Founder & CEO

There are plenty of times when you need to configure your Drupal site to send HTML emails via SMTP server. A common example of an SMTP server is Google apps for business mail.

In this blog post, we'll show you how to use HTML Mail module along with SMTP.

  1. Download and enable HTML Mail, SMTP Authentication Support and Mail System modules.

  2. Go to "Configuration" -> "Mail System". Expand the New Class fieldgroup. Select "HTMLMailSystem" in the format() method dropdown and "SmtpMailSystem" in the mail() method dropdown. Save the form.

  3. Saving the previous form should save HTMLMailSystem_SmtpMailSystem.mail.inc in sites/default/files/mailsystem folder. If there is an error, make sure that the files folder is writable by the web server.

  4. Go to "Configuration" -> "SMTP Authentication Support". Enter SMTP server information. Note that Google uses port number 465 with SSL. Also enter Authentication information, if any. Click the checkbox to allow HTML in the email. Enter Test Email and save the form.

  5. Check your test email. You should have got the following email - Congratulations!! Your SMTP configuration is working.

  6. Go to "Configuration" -> "HTML Mail" -> "Send Test". Enter some HTML in the email body. Change Test mail sending class to HTMLMailSystem_SmtpMailSystem and save the form.

  7. Check your test email. You should have got the email in HTML format. If yes, then you have successfully configured your Drupal instance to send HTML mails using SMTP.

Neerav Mehta

Neerav Mehta

Founder & CEO

Neerav Mehta is the Founder & CEO of Red Crackle. With sterling qualities, Neerav’s technological acumen is firing a generation of progressive companies on the digital path. With an undergraduate degree in Electrical Engineering from India's most prestigious institution IIT Bombay and having spent seven years developing and contributing to the launch of AMD's innovative line of computer products, Neerav founded Red Crackle where he is lauded for his dynamic and innovative genius.

View all posts

>

Read Next

10 Tips For Entrepreneurs In 2015

10 Tips For Entrepreneurs In 2015

Learn more

10 Ways To Increase Productivity At Work

10 Ways To Increase Productivity At Work

Learn more

30 best WordPress widgets for your site

30 best WordPress widgets for your site

Learn more

Let’s get you started!

Contact Us

>

RedCrackle

Explore

About Us

Services

Contact Us

Our address

5346 Gerine Blossom Dr,

San Jose, CA 95123

USA

Socials

Twitter
LinkedIn

© 2023 RedCrackle. All rights reserved.