I am trying to send an email with an attachment when a record is created. This attachment is in the public directory of the project (public / registers_img)
public function build()
{
$this->subject('Correo de notificación');
return $this->markdown('Mails.newRegister')
->with(['employeeName' => $this->name, 'Date'=>$this->date, 'Note'=>$this->note])
->attachFromStorage(public_path('registers_img'.$this->file));
}
When sending the email I get this error
{message: "C:\xampp\htdocs\GMacro\public\registers_img18-11-06_Global_Test.png",…}
exception: "Illuminate\Contracts\Filesystem\FileNotFoundException"