Fixed problems with htmlspecialchars() function for not dupported encodings on newer...
[fa-stable.git] / reporting / includes / pdf_report.inc
index 737a60c83730f201dba877189af6ee42ced8ed4f..f0cad5651c51b34b2d259737c9f865b02b8bb6db 100644 (file)
@@ -425,6 +425,7 @@ class FrontReport extends Cpdf
        {
                global $dflt_lang; // FIXME should be passed as params
 
+               $this->SetLang(@$this->formData['rep_lang'] ? $this->formData['rep_lang'] : $dflt_lang);
                $doctype = $this->formData['doctype'];
                $header2type = true;
 
@@ -952,7 +953,7 @@ class FrontReport extends Cpdf
                if ($SysPrefs->pdf_debug == 1)
                {
                        $pdfcode = $this->Output('','S');
-                       $pdfcode = str_replace("\n", "\n<br>", htmlspecialchars($pdfcode));
+                       $pdfcode = str_replace("\n", "\n<br>", html_specials_encode($pdfcode));
                        echo '<html><body>';
                        echo trim($pdfcode);
                        echo '</body></html>';