Forum


Replies: 3   Views: 3669
Bugs in addtemplate function
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 Chris McLean  · 05-05-2011 - 15:18

Hi,

We've encountered a number of bugs with the addTemplate (CreateDocx.inc) functions:

We have test files that we can supply but the key issues are:
[list]When an array is added using addTemplateVariable (multiple lines) the variable name (ie $VARIABLE$ is not removed[/list]
[list]When a variable is used more than once in a template and replaced with an array only the first instance of the variable is replaced[/list]
[list]When a variable is used more than once in a table only the first instance is replaced[/list]
[list]When a variable is used more than once in a table the table rows can be repeated multiple times (in our case the row was repeated 13 times[/list]

All tests were conducted using clean word docs with the variables pasted in as plain text.

Could you please tell us if these bugs are known and whether they are being fixed?

Thanks

Chris