Forum


Replies: 1   Views: 3526
How i can open docx??
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 waqas123  · 28-01-2016 - 13:41

Fatal error: Class 'TransformDoc' not found in C:\xampp\htdocs\uni\includes\functions.php on line 203

function open_docx(){

require_once 'phpdocx/classes/TransformDoc.inc';
    $docx = new TransformDoc();
    $docx->setStrFile('submitted/2794849631Aresha.docx');
    $docx->generateXHTML();
    $html = $docx->getStrXHTML();
}

Posted by admin  · 28-01-2016 - 14:39

Hello,

The TransformDoc.inc file is an old file that was deprecated since the release of phpdocx 4; the official solution to transform files is using the conversion plugin. Also note that this class is not to open a DOCX but to transform it to HTML.

Although it's not longer supported, it's still included for very simple documents. Please check that you're setting the correct path to the TransformDoc.inc file, it seems that's your error.

Regards.