Answer the question
In order to leave comments, you need to log in
How to pass variables in Laravel Email message in this case?
I send e-mail messages in this way:
Mail::send(['html' => 'emails.start'], ['user' => $user->name], function($message) use ($user)
{
$message->from('[email protected]', 'Имя отправителя');
$message->to($user->email, $user->name)->subject('Тема сообщения.');
});
emails.start
pass $request->message
. Answer the question
In order to leave comments, you need to log in
The documentation also does not say that macaques should write code, but after all, they write it without exception
, if you are not a macaque and approach the documentation not as something terrible and pagan, then you can understand that such a possibility is still indicated in the documentation!
['user' => $user->name, 'message' => $request->message]
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question