Forum


Replies: 7   Views: 551
Generate word document with headings to be copied and pasted in google docs
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 joegraisbery  · 09-01-2023 - 08:11

hi

i tried below code but it not working

$wordStyles = array('<h1>' => 'Heading1' , '<h2>' => 'Heading2'); $html = ' <h1>Heading 1</h1> <h2>Heading 2</h2> '; $docx->embedHTML($html, array('wordStyles' => $wordStyles));

i am generating docx from html and html is dynamic there is no spacific format for docx. how can i create template and define style for heading