I am trying to figure out how to embed HTML text and display with a double underline. I have tried embedHTML with CSS styles to format with a double underline but it only displays the text with a single underline.
$docx = new CreateDocx();
$docx->embedHtml('<html><body><div id="content"><p>test <abbr style="text-decoration: underline; text-decoration-style: double;">abbr</abbr></p></div></body></html>');
$docx->createDocxAndDownload('result.docx');
So I am trying now to use my own Double Underline word style. I have defined a style in the document word.docx for double underline and I can apply it as follows.
$docx = new CreateDocx();
$docx->importStyles('word.docx', 'merge', array('Double Underline'));
$docx->addText('This is some sample character test', array('rStyle' => 'DoubleUnderline'));
But when I try use the same word.docx template Double Underline style with embedHTML it doesn't work.
$docx = new CreateDocx();
$docx->importStyles('word.docx', 'merge', array('Double Underline'));
$wordStyles = array('.dblunderline' => 'DoubleUnderline');
$docx->embedHTML('<p class="dblunderline">my test</p>', array('strictWordStyles' => true, 'wordStyles' => $wordStyles));
$docx->createDocxAndDownload('result.docx');
What am I missing?
Charlotte