mercredi 23 septembre 2020

Laravel DOMPDF failed to open stream: No such file or directory

I am using barryvdh/laravel-dompdf and trying to save a pdf file . it gives me a error

 file_put_contents(core/storage/app/pdf/pdffile50.pdf): failed to open stream: No such file or directory

File is not created

    $pdf = PDF::loadView('invoice::pdf_generate', $data)->setOptions(['dpi' => 115, 'defaultMediaType' 
    => 'media', 'defaultFont' => 'sans-serif', 'isRemoteEnabled' => true])
     ->save('core/storage/app/pdf/pdffile'.$invoice->id.'.pdf');

Does any one why am I getting this error?

This error occurs while task scheduling with a command php artisan recurring:invoice



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire