0

i would like to add a subtable to the an already working table in phpword.

here is what i have done:

$row = $table->addRow();
$cell = $row->addCell();

$subtable_obj = new Table(array('align' => 'center'));
$subtable_row = $subtable_obj->addRow();
$subtable_cell = $subtable_row->addCell();
$subtable_cell->addText("subtable");

// add subtable
$innerCell = $cell->addTable($subtable_obj);

it looks like there is a table because i can see an empty space where the table should go, but there is not text i.e. no "subtable".

does anyone have any idea where the issue could be?

composersucks
  • 61
  • 1
  • 6

0 Answers0