Any example with addchart give error:
Error while trying to write to .docx please check write access.
http:// (...) /phpdocx/examples/Core/addChart/sample_1.php
Failure to create temporary file: Permission denied in /home/(...)/phpdocx/classes/DOCXStructure.inc on line 136
Looking for code od DOCXStructure.inc I think that problem is $path is empty.
This code add '.docx' which is displayed in error.
// check if the path has as extension
if(substr($path, -5) !== '.docx') {
$path .= '.docx';
}
What maybe wrong? What can I do? Others method of phpdocx works. I can read temaplete. Replace text variable. But I I want to add chart this causes exception.
I have checked any different configuration of temp_path. Leave empty, set "/tmp/". Any option didn't resolve problem.