X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=reporting%2Fincludes%2Fpdf_report.inc;h=115fa929d24ab9a34469ed9bffab0707fba42b7d;hb=59840905a38c4e08e5b13fdb7af71ea6dea7b1f0;hp=b3fffbe49e66a79bab907ceca3473446623347df;hpb=ca66b9c3c424ca333f62ba11f528b27f392d7145;p=fa-stable.git diff --git a/reporting/includes/pdf_report.inc b/reporting/includes/pdf_report.inc index b3fffbe4..115fa929 100644 --- a/reporting/includes/pdf_report.inc +++ b/reporting/includes/pdf_report.inc @@ -361,7 +361,7 @@ class FrontReport extends Cpdf if ($pdf_debug == 1) { - $pdfcode = $this->Output(); + $pdfcode = $this->Output('','S'); $pdfcode = str_replace("\n", "\n
", htmlspecialchars($pdfcode)); echo ''; echo trim($pdfcode); @@ -377,8 +377,6 @@ class FrontReport extends Cpdf else { - $buf = $this->Output(); - $len = strlen($buf); $dir = $comp_path.'/'.user_company(). '/pdf_files'; //save the file if (!file_exists($dir)) @@ -388,9 +386,7 @@ class FrontReport extends Cpdf // do not use standard filenames or your sensitive company data // are world readable $fname = $dir.'/'.uniqid('').'.pdf'; - $fp = fopen($fname,'w'); - fwrite($fp,$buf); - fclose($fp); + $this->Output($fname, 'F'); if ($email == 1) { $emailtype = true;