Hi,
I am encountering an issue with the importStyles function:
ErrorException
Undefined variable $name
Classes/Phpdocx/Create/CreateDocx.php:7196
I am following the simple example as outlined on https://www.phpdocx.com/api-documentation/layout-and-general/import-styles-from-a-Word-document-with-PHP.
The source DocX holds the paragraph styles: MatrixBullet, MatrixIndicator and MatrixTitle - parseStyles showed that both the ID and name are identical. I have tried both:
$docx->importStyles(app_path('Segments/_Default/Matrix/Matrix.docx'), 'merge', array('pStyle' => 'MatrixBullet'));
as well as:
$docx->importStyles(app_path('Segments/_Default/Matrix/Matrix.docx'), 'merge', array('MatrixBullet'));
Both result in the abovementioned error.
Any suggestions?