Forum


Replies: 6   Views: 4935
Fatal error: call to a member function addfromstring()
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 pbg@pbgpersonnel.ru  · 17-04-2015 - 15:14

Hello, I try put chart in variable. ..... $chart = new WordFragment(); $data = array( 'Legend 1' => array(20), 'Legend 2' => array(30), 'Legend 3' => array(40) ); $paramsChart = array( 'data' => $data, 'type' => 'pie3DChart' ); $chart->addChart($paramsChart); $docx->replaceVariableByWordML(array('QUESTION_6_CHART' => $chart)); .... Browser shows this is: Fatal error: Call to a member function addFromString() on a non-object in ...../tools/4.6/classes/CreateDocx.inc on line 1188 -------- php check.php OK PHP version is 5.3.18 OK Zip support is enabled. OK DOM support is enabled. OK XML support is enabled. OK Tidy support is enabled. If you have any issue or problem please send us the following info: PHP_VERSION: 5.3.18 PHP_OS: Linux PHP_UNAME: Linux sdi5.example.ru 2.6.33.20-bitrix10 #6 SMP Thu Nov 24 17:29:20 MSK 2011 x86_64 SERVER_NAME: SERVER_SOFTWARE: SERVER_ADDR: SERVER_PROTOCOL: HTTP_HOST: HTTP_X_FORWARDED_FOR: PHP_SELF: check.php ZipArchive: 1 DomDocument: 1 SimpleXMLElement: 1 Tidy: 1