I am trying to create a pdf with dompdf but I get this error when it is trying to add an image.
Uncaught exception 'DOMPDF_Exception' with message 'Function imagecreatefromgif() not found. Cannot convert gif image: E:\APBPEVALUACIONDES/imagenes/header.gif. Please install the image PHP extension.' in E:\APBPEVALUACIONDES\dompdf6\include\cpdf_adapter.cls.php:470
Any one could suggest me the extension for this error.
Thanks.
imagecreatefromgif()is part of the GD PHP extension. In dompdf 0.5.1 or earlier you could get away without GD if you stuck to PNG, but in 0.6.0 GD is pretty much a requirement. Unless your document does not include images, which it obviously does.Check your PHP configuration. So long as you’re using 0.6.0 you can look for any other red flags in the configuration page located at dompdf/www/setup.php (accessed via your web server).
And just FYI, here’s a quick rundown of the requirements for full functionality: