Requirements

Installation

  1. Untar/unzip the source package in a directory accessible by your webserver.
  2. Edit dompdf_config.custom.inc.php (in version 0.6) or dompdf_config.custom.inc.php (version 0.5) to fit your installation. If you leave the DOMPDF_PDF_BACKEND setting at 'auto' dompdf will use the bundled R&OS CPDF class.
  3. Give your webserver write permission on the path specified in DOMPDF_FONT_DIR (lib/fonts by default). Under *nix, ideally you can make the webserver group the owner of this directory and give the directory group write permissions. For example, on Debian systems, Apache runs as the www-data user:
$ chgrp www-data lib/fonts
$ chmod g+w lib/fonts

If your user is not a member of the www-data group or you do not have root privileges, you can make the directory world writable and set the sticky bit:

$ chmod 1777 lib/fonts

Configuration tool

Since 0.6 beta 2, dompdf has a configuration/helper page available at www/setup.php. This page will tell you if an extension is missing, and will check if the temp path is writable. It will also tell you what fonts are installed for the CPDF backend (the one used by default).