-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Closed
Description
Hi
i'm having a problem converting a docx generated by phpword into pdf with mpdf. (you can see issue #210).
Here is the code I'm using :
$phpWord = \PhpOffice\PhpWord\IOFactory::load( UPLOADS_INC . $filename );
$pdfWriter = \PhpOffice\PhpWord\IOFactory::createWriter( $phpWord, 'PDF' );
$pdfWriter->save( UPLOADS_INC . $pdfFilename );
And I keep having this error :
PHP Catchable fatal error: Argument 2 passed to DOMXPath::query() must be an instance of DOMNode, null given, called in /var/www/xxx/PhpWord/Reader/Word2007.php on line 145 and defined in /var/www/xxx/PhpWord/Shared/XMLReader.php on line 99, referer: XXX
Am I doing something wrong ?
I tried to convert a docx that hasn't been generated by phpword and I still have the error.