Trouble with 1.7.8 and external PDF library

Feb 5, 2013 at 9:31 AM
I having trouble with installing version 1.7.8 and using the external domPDF library. I know it's completely down to me doing something wrong but not sure what.

Originall was receiving the error "PDF Rendering library has not been defined". After reading a thread in PDF.php added:
    //$rendererName = PHPExcel_Settings::PDF_RENDERER_MPDF;
    $rendererName = PHPExcel_Settings::PDF_RENDERER_DOMPDF;
    //$rendererLibrary = 'tcPDF5.9';
    //$rendererLibrary = 'mPDF5.4';
    $rendererLibrary = '../libraries/PDF/';

    if (!PHPExcel_Settings::setPdfRenderer($rendererName,$rendererLibrary)) {
    die('NOTICE: Please set the $rendererName and $rendererLibraryPath values at the top of this script as appropriate for your directory structure');
This has stopped that error however the PDF doc are not being created correctly. They won't open as they report its either not a supported file type or because the file is damaged.

Am I adding the above code in the wrong location?

The domPDF libraries are under phpexcel in /libraries/PDF.

Many thanks.
May 21, 2013 at 3:01 AM
Hey bro, If you are try to use dompdf to create pdf file.. you have to download the dompdf @

extract it inside PHPExcel/Writer/dompdf

then try this configuration:
    $rendererName = PHPExcel_Settings::PDF_RENDERER_DOMPDF;

    $rendererLibrary = 'dompdf'; // this is the name of dompdf folder.. 

    $rendererLibraryPath = '/var/www/e_report/system/libraries/PHPExcel/Writer/'.$rendererLibrary;

    if (!PHPExcel_Settings::setPdfRenderer(
        )) {
            'NOTICE: Please set the $rendererName and $rendererLibraryPath values' .
            EOL .
            'at the top of this script as appropriate for your directory structure'

    $objWriter = new PHPExcel_Writer_PDF($this->excelReport);

that should work.. poke me for more info..