vendredi 12 avril 2019

Modify from in laravel 5.1

What if I want to use different email addresses depending on the relatedness of the form.

For example, I want to use donotreply@domain.com for my contact form. Then I want to use myemail@domain.com for my registration form. How can I implement this?

I've already tried to use the from method but didn't work. Please see my code below.

Mail::later(10,
    [],
    compact('inputs'),
    function($m) use ($email, $inputs){
        $m->from('myemail@domain.com', 'Name');
        $m->to($email)->subject($inputs['subject']);
    }
);



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire