How to Send Mail using Sendgrid in Laravel?
https://www.itsolutionstuff.com/post/how-to-send-mail-using-sendgrid-in-laravel-5example.html
How to Send Mail using Sendgrid in Laravel?
First we will add configration on mail. i added my gmail account configration. so first open .env file and bellow code:
.env
Ok, now we need to add secret and domain of sendgrid api configration. So first create new account in sendgrid.com if you don't have before. After registeration active your sendgrid account and set username and password
Now we are ready to send mail for test so first create test route for email sending.
app/Http/routes.php
Ok, now add mail function in HomeController.php file so add this way :
app/Http/Controllers/HomeController.php
At last create email template file for send mail so let's create mailEvent.blade.php file in emials folder.
resources/views/emails/mailEvent.blade.php
Read Also: How to send mail using mailable in laravel 5.3?
Last updated