J
J
Jedi2020-02-25 01:02:36
Laravel
Jedi, 2020-02-25 01:02:36

How do you implement Notification and Mailable?

Good evening!

While I was digging through the documentation and in the articles, my head ached ...

I just want to create an email send to the user after he registers or the "Retrieve password" button.

I want my template. I did vendor:publish . And is it right? I then changed the values ​​there.

I read that Mailable is good if we are going to send only a letter by mailbox, and Notification if we are going to send both sms and letters, for example.

I ask experienced developers to give advice and suggest the right way.

Do I need to do vendor:publish (mail, notification)?
Is it possible to combine Mailable and Notification? For example, so that in Notification we specify the Mailable class.
Where and how best to create email templates?
If the second plan disappears, then how to pass the variable to the templates?

How do you implement it? Tell me, please.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Antonio Solo, 2020-02-25
@solotony

Personally, I don't like the Laravelian way of combing everything under one interface. because no matter how hard you try, sending SMS and sending e-mail are essentially completely different processes.
I just use Mail and am quite satisfied.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question