Forum


Replies: 8   Views: 4998
Add table by wordfragment not working
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 243127387@qq.com  · 14-10-2015 - 14:36

Thank you for your reply, admin. please look the follow example:

$text=array();
// add textFragment
$textstr='PHPDOCX is a very good software! So we have bought the pro 5.0.';
$textFragment = new WordFragment($docx);
$textFragment->addText($textstr);
$text[]=$textFragment;

// add tableFragment
$tableFragment = new WordFragment($docx);
$tabeleArray=array(
     array('11','12'),
     array('21','22')
        );
$tableFragment->addTable($tabeleArray);
$text[] = $tableFragment;

$docx->addText($text);

run the up example, the table can't display properly. I'm very sorry, and always disturb you.