Open
Description
Hi,
I'm trying to merge multiple docx files by adding page break in section but the file is always empty.
$document = new \PhpOffice\PhpWord\PhpWord();
$final_document = \PhpOffice\PhpWord\IOFactory::createWriter($document, 'Word2007');
$section = $document->createSection(($i=0));
foreach($files as $file)
{
$_document = $document->loadTemplate($file);
$section->addPageBreak();
}
$final_document->save($filename);
Thank you
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.