Patient report, download pdf, unknown

Situation
I go to Patient report, I select ‘download pdf’, OpenEMR write ‘unknown’ and it don’t download the pdf.

OpenEMR Version
I’m using OpenEMR version 7.0.0 patch 1.

Browser:
I’m using: Firefox

Operating System
I’m using: Ubuntu Server 22

which version of PHP are you using. Can you post a screenshot? It would help to troubleshoot.

Hi.



PHP 8.1.2

We start with the PHP settings. What is your max vars set to? Did you check your error log to see if there are any entries at the time you are trying to download? Can you check your browser console log to see if there are any clues in there?

max_input_vars = 3000


during your installation process did you install imagemagic? Have you made any modification to forms?

I didn’t install Imagemagic.
I didn’t do modification on forms.

Hi.
I installed with: sudo apt-get install imagemagick.
The problem is continuing.

Could you check your PHP error log which could be at /var/log/apache2/error.log

1 Like




The highlighted line is also part of the error.

what’s the full text of the fatal mpdf error?

The full text is highlighted (color: black).

the part after the client 127.0.0.1 ... that starts with PHP Fatal error: Uncaught Mpdf\\MpdfException: Temporary files directory... is truncated

Could there be a solution?

sure, just was hoping to see the full text of that line, like what’s after the temporary files directory…

guessing there’s a problem with write permissions there

I wrote the following command line:

sudo chown -R www-data:www-data /var/www/html/openemr

sudo chmod 666 /var/www/html/openemr/sites/default/sqlconf.php

The problem is solved.
Thank you.

1 Like

the permissions should be more restrictive and only the sites/default/documents folder should be writeable recursively

Which command should I use in this case?