【发布时间】:2020-10-13 10:20:27
【问题描述】:
我想在我创建的文档中添加页脚,我如何使用 phpword 来做到这一点?
我的模板处理代码:
$template = new \PhpOffice\PhpWord\TemplateProcessor("my-template.docx");
$table = new \PhpOffice\PhpWord\Element\Table();
$table->addRow();
$table->addCell()->addText("test");
$template->setComplexBlock('table_var', $table);
$template->saveAs("new-file.docx");
【问题讨论】: