1. Anuncie Aqui ! Entre em contato fdantas@4each.com.br

How to use an image from AWS S3 in email in a Laravel Project

Discussão em 'Outras Linguagens' iniciado por user761100, Outubro 25, 2024 às 17:52.

  1. user761100

    user761100 Guest

    I have laravel project that sends email using Laravel's builtin mailer (Illuminate\Support\Facades\Mail). I can send text emails without any issue. My site is hosted on AWS and I store images in AWS S3 which is not public. To include an image from S3, I believe that it needs to be embedded. Any suggestion how to do this? I am passing details to the blade file in the build() method like this:

    public function build()
    {
    $this->subject('You have missed an interaction scheduled for ' . $this->schedule->clientname);
    return $this->view('emails.scheduleMissedCheckinToWorker')
    ->replyTo( $this->schedule->schedulerEmail, $this->schedule->schedulername )
    ->with([
    'schedule' => $this->schedule,
    ]);
    ;
    }


    I have full path to the image at AWS. Perhaps I need to Get it and somehow pass it to the blade file. Any help is appreciated.

    Continue reading...

Compartilhe esta Página