Forum


Replies: 7   Views: 3276
Createdocxanddownload no 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 admin  · 11-04-2013 - 12:13

Hello,

This line:

header(
'Content-Disposition: attachment; filename="' . $fileNameDownload .
'.' . $this->_extension . '"'
);

has been fixed in the latest version.

Please note that PHPDocX has createDocxAndDownload method to allow the download of the document. But of course, the headers that this method uses depend on your server. We added createDocxAndDownload but if this method doesn't work in your server you can use createDocx and the add a few lines to download the document.

For example if you integrate PHPDocX in Drupal we don't recommend you to use createDocxAndDownload but the included functions in this CMS.

Regards.