This topic is locked

export pdf (little problem)

7/5/2007 5:58:42 PM
PHPRunner General questions
K
kjp author

Just to report a little mismatch in "export pdf:
in table_list custom "view as " setting:
Change cell color condition:
global $data;

$str = "<table width=100% bgcolor=";

if ($data["Juge_1"]=="Marguet")

$str.="#FFFF00";
if......... and so on...
$str.="><tr><td>".$value."</td></tr></table>";

$value=$str;
result in Export Pdf:

(copy text)
<table width=100%bgcolor=><tr><td>150.000</td></tr></table>

(copy text)

instead of "150.00" in a yellow cell

(ok in excel or word export)
I got others *_list with custom's code:

same result in pdf export
kjp

Alexey admin 7/6/2007

Hi,
HTML formatting won't work in PDF.

You can remove your formatting when exporting to PDF modifying generated ..._export.php file.

Find this line there:

$pdf->MultiCell($colwidth["FieldName"],$rowheight,GetData($row,"FieldName","Custom"));

and replace it with:

$pdf->MultiCell($colwidth["FieldName"],$rowheight,GetData($row,"FieldName",""));



where FieldName is your actual field name.

K
kjp author 7/6/2007

Thanks!