Forum


Replies: 4   Views: 3610
Problem with character '&' generating docx (free version)
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 admin  · 11-04-2013 - 12:13

Hi,

You have to replace the '&' character with his HTML equivalent &# 38; (without spaces). Here you have a conversion table http://www.asciitable.com


Or entering the parameter value within a CDATA section
[code]$docx->addText(’<![CDATA[Testing & character]]>’, $paramsHeader);[/code]


Regards.