barryvdh / laravel-dompdf

A DOMPDF Wrapper for Laravel
MIT License
6.74k stars 971 forks source link

Error in production with FrameDecorator\Block and FrameReflower/Text.php #906

Open dahliar opened 2 years ago

dahliar commented 2 years ago

Its working in my dev environment using PHP 8.1.6, but when i brought my project into production it give me an error such this.

Dompdf\FrameReflower\Text::layout_line(): Argument #1 ($block) must be of type Dompdf\FrameDecorator\Block, null given, called in /home/.../.../vendor/dompdf/dompdf/src/FrameReflower/Text.php on line 399

have been tried to composer update both in my dev and my pro, but still got that error.

anybody found problem like this?

dahliar commented 2 years ago

Trying to resolve it by switch my server php version back to PHP7.4, without any changes in the code, it could print the pdf file.

so i think, its between t

  1. he php 8.1 installation in my server that missing a module or else, or
  2. there is a incompatibility with php 8.1
jochemgruter commented 2 years ago

I am having same issue since I switch to php 8.1

JoseJuni commented 2 years ago

Just make sure that PHP MBSTRING dependency is enabled, it worked for me. In case you don't find it, ask your hosting provider for support.

A domingo, 9/10/2022, 10:36, Jochem Gruter @.***> escreveu:

I am having same issue since I switch to php 8.1

— Reply to this email directly, view it on GitHub https://github.com/barryvdh/laravel-dompdf/issues/906#issuecomment-1272489433, or unsubscribe https://github.com/notifications/unsubscribe-auth/AOBGPBYEPUXGTP5K2BSW7KTWCJ7ZZANCNFSM55HSOPUQ . You are receiving this because you commented.Message ID: @.***>

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Any issues with PDF rendering itself that are not directly related to this package, should be reported on https://github.com/dompdf/dompdf instead. When having doubts, please try to reproduce the issue with just dompdf. If you believe this is an actual issue with the latest version of laravel-dompdf, please reply to this issue so we can investigate further. Thank you for your contribution! Apologies for any delayed response on our side.