Sending Gmail from Local Host - drupal

I'm using the Acquia stack on my localhost (running Vista) and am trying unsuccessfully to send emails. I want to send them via Gmail, and have tried all sorts of settings in the php.ini file. There are no error messages, but no email is delivered. I've gotten no response on the Acquia forum, so I was hoping someone here might be able to help. Thanks very much.

You need http://drupal.org/project/phpmailer or http://drupal.org/project/smtp because you need to authenticate to Google's SMTP.

If you have access to the server your hosting on you can use MSMTP to completely bypass the internal mailing system (sendmail) and use your external provider at the system level. There's a tutorial on it here:
http://floatsolutions.com/blog/2009/12/avoid-complicated-sendmail-setup-using-msmtp-sendmail-emulator/

Related

How to setup email with AWS Lightsail

I've recently hosted my wordpress website through AWS Lightsail. The site has a contact form and a newsletter, but neither are working. I'm also unable to send a password reset email through wordpress, receiving a message that the host may have disabled the mail() function.
How do I setup email on my website? Is it handled through the domain or the host? I've read that I may need to sign up for AWS SES, however I'm unsure how to proceed. My client has also informed me that they have Outlook 365 setup for the domain, but I'm unsure where that fits in.
Apologies for the vagueness. I'm new to hosting websites online, and have been unable to find any useful tutorials/resources so any help would be greatly appreciated.
I would suggest not hosting your client's email through your Lightsail server. There are a lot of extra headaches to consider and there are other services that are more reliable and offer a better more robust user interface than the options available on server.
To get your client a custom domainname email address (ie joe#domainname.com) here are two options:
Zoho -
Cost: FREE
You can sign up here: https://www.zoho.com/workplace/pricing.html?src=zmail
You need to verify the domain name for this to work (either by adding an HTML file to the site or a CNAME to the domain)
GSuite by Google - Cost: $5/user/month
You can sign up here: https://inbox.google.com/u/0/search/google%20suite#m_-1052842142248281614_
You can also get some good promotional codes to get 20% off the first year - here's one: 9746YLRVNWERPAH
And, to your question about making sure forgot password emails are sent, make sure sendmail is installed on the server (apt-get install sendmail), that the /etc/hosts file contains the following
127.0.0.1 localhost localhost.localdomain yourhostnamehere
and that port 25 is open on the server.

Using Fake SMTP Server to read sent emails on localhost for Woocommerce

I am using WooCommerce with Wordpress and I want to view the emails that get sent out when an order is complete on my localhost development environment.
I have the program Fake SMTP Server setup to listen at port 25 but no email appears to arrive within the app?
Any ideas what this could be - I am using a recent installation of XAMPP
Mailnest.io should work for you
I'm not sure why Fake SMTP wouldn't be working for you. Might I suggest giving MailSlurper a try. Local mail server, web-based interface. Full disclosure - I am the author of MailSlurper.
For anyone else looking to use test email in WordPress please take a look at Imitate Email (it is one of my projects).
Free to get going, tested with WordPress and a 1 line JS will drop it in to your WordPress site so that you can see test emails as you work on WordPress.

Wordpress smtp.google.com issue on Windows azure

When sending gmail SMTP mail from Wordpress on a windows Azure website, something goes terribly wrong.
I managed to send once or twice a message, but mostly the authentication get's denied. And we get a lot of message of gmail, asking if we authenticated. Or if we are hacked.
Now the weird thing is that when i log in to the Gmail account on MY computer. Go to the following url and accept: https://accounts.google.com/b/0/DisplayUnlockCaptcha .
it suddenly works (for some time, and only form my pc).
As the worpress website is hosted on a Windows azure website, we can not log in on the server to navigate to this url:https://accounts.google.com/b/0/DisplayUnlockCaptcha from there.
Anyone got a solution for this issue? (As i don't have RDP on our azure Website, we can't access the machine to whitelist the ip).
Reference: https://support.google.com/mail/answer/10336?hl=en
You can try to generate an application-specific password for your gmail SMTP if you enable 2-step verification. That may help you to avoid manual CAPTCHA resolve.
I would still like to recommend SendGrid as you are using Azure. SendGrid is provided as an add-on in Azure. You can easily apply a SendGrid service and get 25,000 email per month for free.

Email from address changes once it is delivered

I am currently doing work for a client and am running into a bit of an issue when an email receipt is sent to the user. What is happening is that once the email address is delivered the from address is completely different then the one I am using. I have tried using a few different email addresses and they work fine. It's only the one that they really want to use that is causing the problem.
I don't have access to their site and am also unsure of how the mail is sent. What I am wondering is if anyone knows the questions that I can ask to figure out what is going on on there end. They recently changed who was handling their site so I have a feeling something may be getting mixed up.
The site is built with WordPress and is using Gravity Forms. From the changed email address I can see that they are using Bluehost since the email changes from #companyname to #boxXXX.bluehost.com.
Email servers are not my area of expertise so I really appreciate any help.
Very likely their Wordpress website is sending emails through the wp_mail() function which is nothing more than the usual mail() function from PHP.
By default if you send an email through this method it will display either the hostname of the server where the website is sitting or the SMTP server, in this case boxXXX.bluehost.com depending on what's the policy of Bluehost regarding sending e-mails.
Generally hosting provider switch off the php mail() function in shared hosting environments to prevent spam and they provide you with the details to connect to their SMTP server and send legit e-mails, if their server is sitting on a shared hosting I think you might need support from Bluehost directly, explain to them the situation and they will help you throughout the process.
If the website is sitting on a virtual dedicated server then they need to do additional configuration on it. In this case what I do is to access onto cPanel and create a new mailbox with the address I want to send from (wordpress#domain.com, info#domain.com, whatever the client wants to be displayed) and configure Wordpress to send with through the VPS SMTP (you can do that easily with this nice plugin: http://wordpress.org/plugins/wp-mail-smtp ) with the address and password you chose when creating the email account on cPanel.
From now on the email will show the correct address.
Also you might want to increase the deliverability of your message and to instruct the email servers that are receiving the email that you're using a legit account, so you should add to their DNS both DKIM and SPF server records.
Note: I suggest you to be extremely cautious when playing around with DNSes, especially when touching email related records. If you are not familiar on how setup new and change the current existing records ask for help from someone who has quite good experience and to guide you through the process so you understand how it works and the consequences of a bad formatted or clashing records.
We recently had a really bad couple of hours at work when someone touched the company records without any clue of what was doing and we ended up with no email and website working for several hours.

How do I configure TFS to work with GMail to send TFS Alerts?

Environment: Windows Server 2008, IIS 7.0, TFS 2008
We run Google Apps for email and I'm having a heck of time setting up TFS to send alerts to our Google hosted mail.
I googled around and found a couple of workarounds however none have worked for me. Any pointers graciously accepted.
Have you tried setting up an SMTP server on the same box as TFS, then configuring it to forward to GMail? That sounds like the easiest solution.
Alternatively, you could write a SOAP endpoint that handled TFS events with as many customizations as you want. This is a little more work but a lot more flexible.
I just ran through this problem in TFS-2013.
I think the root of the problem is that Apps must sign into Google Securely. For secondary apps, that means oauth. For those that can't, Google needs "Application Specific Passwords". Since it can't really trust the email application, it requires you to generate a random password for that specific account.
The solution for me was:
Enable Email Alerts
SMTP Server: smtp.gmail.com
port: 587
SSL Required: Yes
send from: email#mydomain.com
authentication:
username: mygmail#gmail.com
password: RANDOM APP PASSWORD
Can't you just configure TFS to send outgoing email through the Gmail servers?
http://msdn.microsoft.com/en-us/library/ms400808(VS.80).aspx
Does that not do what you need, or am I missing part of the question? We're using a local SMTP server to send email out, but I don't see a reason why you couldn't use a remote one instead.
I verified that WernerCD AppPassword solution works.

Resources