Skip to content

Commit efcc32b

Browse files
committed
pdf: translate text html entities to utf8
1 parent 8a45fae commit efcc32b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

agility/server/pdf/print_common.php

+3-2
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,9 @@ class PrintCommon extends FPDF {
5656
protected $centro;
5757

5858
function Cell($w, $h=0, $txt='', $border=0, $ln=0, $align='', $fill=false, $link='') {
59-
// convert to iso-latin1
60-
$txt=utf8_decode($txt);
59+
if (!is_string($txt)) { parent::Cell($w, $h, $txt, $border, $ln, $align, $fill, $link); return; }
60+
// convert to iso-latin1 from html
61+
$txt=utf8_decode(html_entity_decode($txt));
6162
// translate federation related strings
6263
$txt=$this->federation->strToFederation($txt,$this->prueba->RSCE);
6364
// let string fit into box

0 commit comments

Comments
 (0)