PHPWord/docs/installing.rst

56 lines
1.3 KiB
ReStructuredText

.. _setup:
Installing/configuring
======================
Requirements
------------
Mandatory:
- PHP 5.3+
- PHP `Zip <http://php.net/manual/en/book.zip.php>`__ extension
- PHP `XML Parser <http://www.php.net/manual/en/xml.installation.php>`__ extension
Optional PHP extensions:
- `GD <http://php.net/manual/en/book.image.php>`__
- `XMLWriter <http://php.net/manual/en/book.xmlwriter.php>`__
- `XSL <http://php.net/manual/en/book.xsl.php>`__
Installation
------------
PHPWord is installed via `Composer <https://getcomposer.org/>`__.
You just need to `add dependency <https://getcomposer.org/doc/04-schema.md#package-links>`__ on PHPWord into your package.
Example:
.. code-block:: json
{
"require": {
"phpoffice/phpword": "v0.13.*"
}
}
If you are a developer or if you want to help us with testing then fetch the latest branch for developers.
Notice: all contributions must be done against the developer branch.
Example:
.. code-block:: json
{
"require": {
"phpoffice/phpword": "dev-develop"
}
}
Using samples
-------------
After installation, you can browse and use the samples that we've
provided, either by command line or using browser. If you can access
your PHPWord library folder using browser, point your browser to the
``samples`` folder, e.g. ``http://localhost/PhpWord/samples/``.