You need to add the Host
parameter
$mail->Host = "ssl://smtp.gmail.com";
Also, check if you have open_ssl
enabled.
<?php echo !extension_loaded('openssl')?"Not Available":"Available";
Related Posts:
- Stop the execution of foreach loop which extract data from array?
- Send Custom Post Notification to Followers
- How can I send an email using PHP?
- What is the difference between ports 465 and 587?
- WordPress refuses to send mail, “…your host may have disabled the mail() function”
- How do you update user_email on the front end in WP 3.3?
- Missing URL in password reset email
- User Without Email?
- Allow Duplicate Email Address for Different Users
- How do I override the Message-ID header of wp_mail function?
- WP Cron emails not working
- Few chars getting replaced with ‘=’ in mail content in wp_mail()
- Locked out of my own blog and password reset not working
- Change Password notification text on mail
- On form submission how to send 2 email to different users
- email wordpress users using BCC
- email sends from [email protected] even though I have it set to something else
- Mail not sent when I set HTML headers
- Joining confirmation email
- How to sent one form values to 2 different sites in wordpress
- How to setup SMTP for only one specific wp_mail()
- Woocommerce HTML email option unavailable
- Email notification after registration in WordPress
- Trigger Woocommerce New User Email
- Processing a subscription form with POST method?
- WordPress E-mail Config
- Setting up 2 SMTP accounts: 1 for wordpress and 1 for woocommerce
- wordpress do not let user registered with info@ email and other reserved emails to get registered by users
- Emails marked as spam because it’s contain via box4231.bluehost.com
- Limit number of emails per second
- WordPress reset password email is not working – woocommerce and checkmail does work
- Throttling email frequency
- User registration email and let user choose pasword
- WordPress unable to send mail
- How to retrieve the sender email with wp_mail()?
- Not able to send links in email after setting header
- 2 Email addresses for each user
- Emailing passwords: Setup installed on home server using XAMPP
- Mail function is not working
- wp_mail_from is ignored
- PAGE Specific Email Notifications
- Send bulk emails without timeout
- How to edit the WordPress e-mail that gives the user their password? [duplicate]
- Do action for only switch status for publish_post
- Change the Sender(not From) on wp_mail() function [closed]
- Is Postfix required for WordPress contact forms in general?
- Mailing list sign up form without plugin
- Adding “reply-to” in the email [closed]
- WordPress Won’t Send Email When a User Register
- Programming WordPress to Send an Email on Registration Form Submit?
- How do I troubleshoot registration/password email errors?
- Does WordPress require port 25 for email?
- wp_mail not sending email on custom function
- Send email with list of active plugins upon activation/deactivation
- Is there a plugin that will let you do actions by mail? [closed]
- difference between sanitize_email ,FILTER_VALIDATE_EMAIL and input email type in html5
- Send email daily using `wp_mail`
- How to send confirmation email after payment made via paypal?
- Changing email “From” address
- wp_mail() won’t send mail when it’s a variable, only when hard coded
- WordPress and IPN problem
- Add “Email Image” button with Hyperlink for individual images [closed]
- I just had an email from wordpress. what does it mean?
- Mail through Cron Execution does not work!
- Contact form – problem with displaying message about sent mail
- See if the email exists or not
- How to setup the Email piping in WordPress plugin?
- Is it secure to use SMTP password in .php file in WordPress website?
- Need to suspend RSS feed while repairing missing old post
- How to recover one of WP email addresses?
- Send email using wordpress plugin on behalf of someone with their permission
- How to apply a function to the value $email of get_user_by to override email_exists?
- Activation email to change admin address not being sent to Gsuite email account
- Send email with Content-Type text/plain
- How to change a wordress plugin php code in my child’s functions.php file?
- forgot password page with expiry link email of 60 minutes
- I need to verify emails when users signup
- Changing default WPMU emails to be send thorugh Campaign Monitor Transactional emails
- Where is the account email address located?
- wp_mail() not sending emails with ajax
- SMTP not working for Comments Email Notifications
- wordpress wp mail not changing sender mail
- changing notification emails from WordPress @mydomain.net to something else
- Send Bulk Email without them going to spam
- How can I send an email 24 hours after first email?
- WordPress doesn’t send SMTP email even by phpmailer hook
- Whitelist email sent by WordPress
- Asynchronous emailing
- Using Custom Javascript and pHp to send email to myself when a user clicks on an input button but only works on Chrome, IE, and Micorosft Edge
- Duplicate notifications for new user registration
- get_post_meta is always empty when I use wp_mail
- Cron job to call php to email last 24 hours posts
- Create WP account from an external email form submission?
- Display “a generated one [avatar] based on their e-mail address”
- Allow users to register as a higher role than default with code
- Can wordpress users check GMAIL (G Suite) inbox & send email from their membership account on WordPress? [closed]
- What’s the simplest way to send WordPress posts to a Mailchimp list? [closed]
- Send email on creation of custom post type and use get_post_meta()
- Having Issue on Receiving Emails From @Gmail.com or @Yahoo. in WordPress Using PHP Mail Function
- How to add verification on email address change?