X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=CRM%2FUtils%2FPDF%2FUtils.php;h=f7dc760449e4427d7b694cf47e1f6f799e0ef6e3;hb=f28ac29c413280dc455dadca2d3a6da44b608a47;hp=d6ad7bef57a7949ec978dd6f9ca8c54569bfaba4;hpb=b7ff0a0a5544c5a5d510c685c8fdbdaecad7a5d0;p=civicrm-core.git diff --git a/CRM/Utils/PDF/Utils.php b/CRM/Utils/PDF/Utils.php index d6ad7bef57..f7dc760449 100644 --- a/CRM/Utils/PDF/Utils.php +++ b/CRM/Utils/PDF/Utils.php @@ -190,8 +190,11 @@ class CRM_Utils_PDF_Utils { * @return string */ public static function _html2pdf_dompdf($paper_size, $orientation, $html, $output, $fileName) { - require_once 'packages/dompdf/dompdf_config.inc.php'; - spl_autoload_register('DOMPDF_autoload'); + // CRM-12165 - Remote file support required for image handling. + define('DOMPDF_ENABLE_REMOTE', TRUE); + define('DOMPDF_ENABLE_AUTOLOAD', FALSE); + require_once 'vendor/dompdf/dompdf/dompdf_config.inc.php'; + $dompdf = new DOMPDF(); $dompdf->set_paper($paper_size, $orientation); $dompdf->load_html($html);