Forum


Replies: 2   Views: 3352
Addhtml not working
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 mahnid  · 28-04-2012 - 17:58

I've searched the forum and can't find a solution. Sorry it it's already been covered.

I can not get addHTML to work. either the resulting document is corrupted (openoffice, etc. can't open it) or the document is ok but the HTML content is missing.

My code is exactly as in the examples. Installation of PHP, etc. look ok also.

Where am I going wrong..... please help.

ta,

Andy

[code]<?PHP

require_once '../phpdocx/classes/CreateDocx.inc';

$docx = new CreateDocx();

$docx->addText('HTML content');

$html= '<p><strong>PHPDOCX</strong> is a PHP library designed to generate completely dynamic and fully customizable Word documents.</p>';

$docx->addHTML($html);

$docx->addText('End HTML content');

$docx->createDocx('../docx/example_html');
?>[/code]