Open renatobez opened 1 year ago
Version of GLPI? Version of the plugin? Which fields do you want to print in PDF and for which item?
GLPI: GLPI 10.0.5 Plugin: 3.0.0 I'm trying to print the page of a ticket, using the side tab of the plugin, when I click on generate pdf, it causes an error.
Which part of the ticket do you want to print?
basically all ticket fields
can you give me errors in glpi php-error.log? (in files directory/_logs)
You have this error where some data are missing in the export. You have the complete error in glpi logs
yes basically these are the error messages:
[2023-02-10 08:22:13] glpiphplog.WARNING: *** PHP Warning (2): include_once(): Failed opening '/var/www/html/glpi/plugins/pdf/vendor/autoload.php' for inclusion (include_path='.:/usr/share/php') in /var/www/html/glpi/plugins/pdf/setup.php at line 38 Backtrace : plugins/pdf/setup.php:38 include_once() src/Plugin.php:294 plugin_init_pdf() src/Plugin.php:248 Plugin::load() inc/includes.php:86 Plugin->init() ajax/actorinformation.php:39 include()
[2023-02-10 08:22:13] glpiphplog.WARNING: *** PHP Warning (2): include_once(/var/www/html/glpi/plugins/pdf/vendor/autoload.php): failed to open stream: No such file or directory in /var/www/html/glpi/plugins/pdf/setup.php at line 38 Backtrace : plugins/pdf/setup.php:38 include_once() src/Plugin.php:294 plugin_init_pdf() src/Plugin.php:248 Plugin::load() inc/includes.php:86 Plugin->init() ajax/comments.php:37 include()
[2023-02-10 08:22:13] glpiphplog.WARNING: *** PHP Warning (2): include_once(): Failed opening '/var/www/html/glpi/plugins/pdf/vendor/autoload.php' for inclusion (include_path='.:/usr/share/php') in /var/www/html/glpi/plugins/pdf/setup.php at line 38 Backtrace : plugins/pdf/setup.php:38 include_once() src/Plugin.php:294 plugin_init_pdf() src/Plugin.php:248 Plugin::load() inc/includes.php:86 Plugin->init() ajax/comments.php:37 include()
[2023-02-10 08:22:15] glpiphplog.WARNING: *** PHP Warning (2): include_once(/var/www/html/glpi/plugins/pdf/vendor/autoload.php): failed to open stream: No such file or directory in /var/www/html/glpi/plugins/pdf/setup.php at line 38 Backtrace : plugins/pdf/setup.php:38 include_once() src/Plugin.php:294 plugin_init_pdf() src/Plugin.php:248 Plugin::load() inc/includes.php:86 Plugin->init() front/helpdesk.public.php:38 include()
Which directory had you upload her:https://github.com/yllen/pdf/releases? You must already upload the first one glpi-pdf-3.0.0.tar.gz
I´m using GLPI 10.0.10 and plugin Print with version 3.0.0. I had the same error. I fix this including the command bellow in common.class.php file, on line 418:
final function generatePDF($tab_id, $tabs, $page=0, $render=true) {
...
ob_end_clean(); /* Fix error of TCPDF */
if($render) {
$this->pdf->render();
} else {
return $this->pdf->output();
}
}
Could you evaluate this solution?
I installed the plugin and until then it was printing normally glpi, now this error is appearing and I don't know how to solve it: TCPDF ERROR: Some data has already been output, can't send PDF file