X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=reporting%2Fincludes%2Ftcpdf.php;h=ba54e66a3ea08b8a96f70a25d25fb50be43c1516;hb=3ff9ed87cb909f19c8fe3e7dfda5df79d0c01a6c;hp=35e69ddae362025a9eb374c063b3f493d68474c9;hpb=f12dbe7523bb1abc6cd69b009ef8f0be838f5348;p=fa-stable.git
diff --git a/reporting/includes/tcpdf.php b/reporting/includes/tcpdf.php
index 35e69dda..ba54e66a 100644
--- a/reporting/includes/tcpdf.php
+++ b/reporting/includes/tcpdf.php
@@ -1756,7 +1756,8 @@ if (!class_exists('TCPDF')) {
*/
function Error($msg) {
//Fatal error
- die('TCPDF error: '.$msg);
+ display_error('TCPDF error: '.$msg);
+ exit;
}
/**
@@ -2602,9 +2603,9 @@ if (!class_exists('TCPDF')) {
if (isset($cw)) {
unset($cw);
}
- include($this->_getfontpath().$file);
+ @include($this->_getfontpath().$file);
if ((!isset($type)) OR (!isset($cw))) {
- $this->Error('Could not include font definition file');
+ $this->Error("Could not include font definition file: ".$file);
}
$i = count($this->fonts) + 1;
// register CID font (all styles at once)
@@ -5005,7 +5006,8 @@ if (!class_exists('TCPDF')) {
* @access protected
*/
function _putheader() {
- $this->_out('%PDF-'.$this->PDFVersion);
+ $this->buffer = '%PDF-'.$this->PDFVersion."\n".$this->buffer;
+// $this->_out('%PDF-'.$this->PDFVersion);
}
/**
@@ -5727,7 +5729,7 @@ if (!class_exists('TCPDF')) {
*/
function unhtmlentities($text_to_convert) {
if (!$this->isunicode) {
- return html_entity_decode($text_to_convert);
+ return html_entity_decode($text_to_convert, ENT_QUOTES);
}
return html_entity_decode_php4($text_to_convert);
}