簡體   English   中英

如何在Laravel中的重置密碼電子郵件中包含徽標

[英]How to include Logo in Reset password email in laravel

我正在嘗試自定義重置密碼刀片。

至今,

我已將此代碼放在User.php模型中。

public function sendPasswordResetNotification($token)
{
    $this->notify(new ResetPasswordNotification($token));
}

和,

php artisan make:notification MyOwnResetPassword我使用此命令發布自定義通知

public function toMail($notifiable)
{

    return (new MailMessage)
                ->subject('Reset Password')
                ->line('You are receiving this email because we received a password reset request for your account.')
                ->action('Reset Password', url('admin/password/reset/'.$this->token, false))
                ->line('If you did not request a password reset, no further action is required.');
} 

問題是如何添加徽標?

任何幫助或參考都很好

謝謝

在文檔中( https://laravel.com/docs/5.3/notifications#mail-notifications ),它表示您的新MailMessage正在發送格式化的消息。

您也可以自定義模板:

在resources / views / vendor / notifications目錄中

您可能需要在運行以下命令之前: php artisan vendor:publish --tag=laravel-notifications

您可以在此處查看所有文檔: https : //laravel.com/docs/5.3/notifications#customizing-the-templates

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM