Forum


Replies: 1   Views: 398
Memory consumption
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 didiergm  · 12-10-2019 - 05:57

I routinely generate PDF using mPDF but on larger documents (mainly reports off a databse) I encounter a memory issue and was wondering if in phpdocx the whole document was kept in memory or if it is possible to have each page dumped to the output file during the production process.

Although there usually is a  performance hit, it solves the memory consumption issue 

Posted by admin  · 12-10-2019 - 10:24

Hello,

The whole document is loaded in memory, DOCX documents work with sections, not with pages. Anyway, working with DOCX documents is much faster than PDF documents.

Premium licenses options to get the best performance not available in Basic and Advanced licenses, such as working with in-memory documents and streams (https://www.phpdocx.com/documentation/cookbook/ Performance section).

Regards.