Forum


Replies: 1   Views: 3920
Repeating tables - multiple iterations of the same table?
Topic closed:
Please note this is an old forum thread. Information in this post may be out-to-date and/or erroneous.
Every phpdocx version includes new features and improvements. Previously unsupported features may have been added to newer releases, or past issues may have been corrected.
We encourage you to download the current phpdocx version and check the Documentation available.

Posted by donnav  · 20-06-2014 - 16:47

I have many types of reports that contain repeating tables, i.e., the data loops through the table lines, makes a page break, then starts a new iteration of that table for another category of data, etc. Then after it loops through x tables, it then has several different summary tables. In /examples/Templates/replaceTableVariable/sample_1.php, I tried adding another $docx->replaceTableVariable($data), but it does not show a second table with new data. I see only the first table.

Posted by admin  · 23-06-2014 - 14:59

Hello, After the table is replaced, it's not longer available. You need to add as many tables as you need to replace; or create new tables and add them to the document. Regards.