Integrate phpdocx with CodeIgniter

Using phpdocx with CodeIgniter is as simple as copying the phpdocx content package to the application/libraries/phpdocx directory and load the CreateDocx class.

To have the phpdocx API methods available, just load the library in the controller:

In order to save the document, the documents folder in the APPATH path must have read/write permissions.


To run phpdocx with CodeIgniter 4 it is mandatory to use the package that supports namespaces. This package is available for Advanced and Premium licenses.