$phpword = \PhpOffice\PhpWord\IOFactory::load($newDoc,'Word2007'); $objWriter = \PhpOffice\PhpWord\IOFactory::createWriter($phpword); echo $content = $objWriter->getContent();
$phpword = \PhpOffice\PhpWord\IOFactory::load($newDoc,'Word2007'); $objWriter = \PhpOffice\PhpWord\IOFactory::createWriter($phpword); echo $content = $objWriter->getContent();