You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have been having some problems with the ioFactory reading and writing. I am running the current version of php7, and have a clean composer install. I looked over the change log and it appeared the font classes were moved to the common code... so I am not sure what to do from here. Any suggestions would be appreciated.
Sample 11 ReadWord97
07:22:18 Reading contents from resources/Sample_11_ReadWord97.doc
Fatal error: Uncaught Error: Class 'PhpOffice\PhpWord\Reader\Style\Font' not found in /raid/www/dbs_dev/vendor/phpoffice/phpword/src/PhpWord/Reader/MsDoc.php:1693 Stack trace: #0 /raid/www/dbs_dev/vendor/phpoffice/phpword/src/PhpWord/Reader/MsDoc.php(1484): PhpOffice\PhpWord\Reader\MsDoc->readPrl('\xEC\xA5\x01\x01M \t\x04\x00\x00\xF8\x12\xBF\x00\x00...', 3022, 43) #1 /raid/www/dbs_dev/vendor/phpoffice/phpword/src/PhpWord/Reader/MsDoc.php(1114): PhpOffice\PhpWord\Reader\MsDoc->readRecordPlcfBteChpx() #2 /raid/www/dbs_dev/vendor/phpoffice/phpword/src/PhpWord/Reader/MsDoc.php(125): PhpOffice\PhpWord\Reader\MsDoc->readFibContent() #3 /raid/www/dbs_dev/vendor/phpoffice/phpword/src/PhpWord/IOFactory.php(92): PhpOffice\PhpWord\Reader\MsDoc->load('resources/Sampl...') #4 /raid/www/dbs_dev/vendor/phpoffice/phpword/samples/Sample_11_ReadWord97.php(8): PhpOffice\PhpWord\IOFactory::load('resources/Sampl...', 'MsDoc') #5 {main} thrown in /raid/www/dbs_dev/vendor/phpoffice/phpword/src/PhpWord/Reader/MsDoc.php on line 1693
The text was updated successfully, but these errors were encountered:
Hi @Paperclip-Systems,
just came across the same issue, turned out its due to a missing namespace, just add
use PhpOffice\PhpWord\Style; in the MsDoc.php and you will be good to go.
I have been having some problems with the ioFactory reading and writing. I am running the current version of php7, and have a clean composer install. I looked over the change log and it appeared the font classes were moved to the common code... so I am not sure what to do from here. Any suggestions would be appreciated.
Sample 11 ReadWord97
07:22:18 Reading contents from
resources/Sample_11_ReadWord97.doc
Fatal error: Uncaught Error: Class 'PhpOffice\PhpWord\Reader\Style\Font' not found in /raid/www/dbs_dev/vendor/phpoffice/phpword/src/PhpWord/Reader/MsDoc.php:1693 Stack trace: #0 /raid/www/dbs_dev/vendor/phpoffice/phpword/src/PhpWord/Reader/MsDoc.php(1484): PhpOffice\PhpWord\Reader\MsDoc->readPrl('\xEC\xA5\x01\x01M \t\x04\x00\x00\xF8\x12\xBF\x00\x00...', 3022, 43) #1 /raid/www/dbs_dev/vendor/phpoffice/phpword/src/PhpWord/Reader/MsDoc.php(1114): PhpOffice\PhpWord\Reader\MsDoc->readRecordPlcfBteChpx() #2 /raid/www/dbs_dev/vendor/phpoffice/phpword/src/PhpWord/Reader/MsDoc.php(125): PhpOffice\PhpWord\Reader\MsDoc->readFibContent() #3 /raid/www/dbs_dev/vendor/phpoffice/phpword/src/PhpWord/IOFactory.php(92): PhpOffice\PhpWord\Reader\MsDoc->load('resources/Sampl...') #4 /raid/www/dbs_dev/vendor/phpoffice/phpword/samples/Sample_11_ReadWord97.php(8): PhpOffice\PhpWord\IOFactory::load('resources/Sampl...', 'MsDoc') #5 {main} thrown in /raid/www/dbs_dev/vendor/phpoffice/phpword/src/PhpWord/Reader/MsDoc.php on line 1693
The text was updated successfully, but these errors were encountered: