In the order template, this error shows up in the generated PDFs when adding standard JPG images. We're running Commerce 1.2.x on PHP70.

It could be related to this dompdf issue, but how do we fix it in Craft Commerce?

up vote 2 down vote accepted

Try setting:

'pdfAllowRemoteImages' => true,

in your commerce.php config file.

  • That worked! Stupid question but updates won't override the config file right? – biko Jul 6 at 2:47
  • 1
    No, the commerce.php config file you create in your /config directory will never be overridden. Just don't edit the config.php file in the commerce directory. – Luke Holder Jul 6 at 4:18
  • Thx. Good thing I asked since I actually modified the core commerce/config.php which is definitely not the way to go, and didn't seem right either. I've created a craft/config/commerce.php file now. Thanks again! – biko Jul 6 at 5:08

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.