Forum


Replies: 4   Views: 4491
Embedhtml(): how to style bold text when strictwordstyles = true
Topic closed:
Please note this is an old forum thread. Information in this post may be out-to-date and/or erroneous.
Every phpdocx version includes new features and improvements. Previously unsupported features may have been added to newer releases, or past issues may have been corrected.
We encourage you to download the current phpdocx version and check the Documentation available.

Posted by admin  · 21-12-2015 - 08:07

Hello,

UPDATE: phpdocx 9.5 added support  for custom character styles when importing HTML.

No, there isn't support of Word character styles when importing HTML; you need to add them setting strictWordStyles as false and through HTML styles; or don't use HTML content but native methods: addList, addText, WordFragments...

It's explained on the documentation pages:

'One may use native Word styles for paragraphs and tables.'

To set span styles you need to set strictWordStyles as false and add the styles inline or through CSS. If some styles aren't applied then they're not supported.

Regards.