Error message in V5 TCPDF action

nlheath 02 Jun, 2015
I have a form whose On Submit section has a custom code action and a TCPDF action. The custom code retrieves multiple rows from a database and formats them into an HTML table. The TCPDF Contents section is blank, so it should create a pdf document containing this table. With the View option in TCPDF set to "save to server", the table is displayed correctly on the screen, but is followed by this message:

Warning: Invalid argument supplied for foreach() in /.......components/com_chronoforms5/chronoforms/actions/tcpdf/tcpdf/tcpdf.php on line 23773
Same message is repeated with "on line 23805".
No pdf file is generated.

SInce the table is displayed correctly, I think my custom code is retrieving the rows and formatting the table correctly. The only "foreach" in my custom code processes the retrieved rows, and even if I remove it and retrieve and display only a single row, I get the same message. Any idea what the problem could be?
GreyHead 03 Jun, 2015
Hi nlheath,

Looking at the TCPDF code those lines appear to be handing page-breaks in tables so I guess that the problems are somehow related to that. These are Warnings, not errors so the effect is mostly cosmetic. Please try setting your Site Error Reporting to System Default or None, that should hide the errors and the PDF may then work OK.

Bob
This topic is locked and no more replies can be posted.

VPS & Email Hosting 20% discount
hostinger