Replies: 1   Views: 2036
Table in a other 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 kpholland  · 13-05-2016 - 10:07

Is it posible to put a table in a other table?

I have the code below that puts two table among each other. Ant i want it in each other....

$paramsTable = array(
    'border' => 'single',
    'tableAlign' => 'center',
    'borderWidth' => 10,
//    'borderColor' => 'B70000',
 'backgroundColor' => 'cccccc',
 'borderColor' => 'cccccc',
// 'border' => 'single',
// 'cellMargin' => 200,
// 'fitText' => 'on',
    'textProperties' => array('bold' => false, 'font' => 'Verdana', 'fontSize' => 10),

$wf = new WordFragment($docx, 'document');
$wf->addTable($Array_Table_Value, $paramsTable);

$wf1 = new WordFragment($docx, 'document');
$wf1->addTable($Array_Table_Memo, $paramsTable);
$docx->replaceVariableByWordFragment(array('Array_Table_Value' => $wf), array('type' => 'block'));
$docx->replaceVariableByWordFragment(array('Array_Table_Memo' => $wf1), array('type' => 'block'));