- 本文默认你已经知道如何使用phpword插入表格。
- phpoffice的表格合并是通过修改表格样式来实现的,假如我们有如图表格:
我们要把1234合并起来:
那么我们就要修改1234表格的vMerge样式。
$table->addCell(100, ["vMerge" => "restart"])->addText("1");
$table->addCell(100, ["vMerge" => "continue"]);
$table->addCell(100, ["vMerge" => "continue&