• Resolved KovaZg

    (@kovazg)


    When I click on plugin under Woocommerce in admin panel on the right side I see error:

    Error trying to generate document: Unable to load module (“/usr/lib64/GraphicsMagick-1.3.38/modules-Q16/coders/url.la: file not found”)

    If I click on PDF invoice I get more detailed error:

    Exception: Unable to load module ("/usr/lib64/GraphicsMagick-1.3.38/modules-Q16/coders/url.la: file not found")
    /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/lib/Cpdf.php (5662)
    #0 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/lib/Cpdf.php(5662): Gmagick->__construct('file:///home/fu...')
    #1 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/lib/Cpdf.php(5845): Dompdf\Cpdf->addImagePngAlpha('file:///home/fu...', 57.442913385827, 699.40771653543, 113.38582677165, 113.38582677165, 6)
    #2 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/src/Adapter/CPDF.php(669): Dompdf\Cpdf->addPngFromFile('file:///home/fu...', 57.442913385827, 699.40771653543, 113.38582677165, 113.38582677165)
    #3 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/src/Renderer/Image.php(65): Dompdf\Adapter\CPDF->image('file:///home/fu...', 57.442913385827, 29.096456692913, 113.38582677165, 113.38582677165, 'normal')
    #4 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/src/Renderer.php(289): Dompdf\Renderer\Image->render(Object(Dompdf\FrameDecorator\Image))
    #5 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/src/Renderer.php(128): Dompdf\Renderer->_render_frame('image', Object(Dompdf\FrameDecorator\Image))
    #6 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/src/Renderer.php(195): Dompdf\Renderer->render(Object(Dompdf\FrameDecorator\Image))
    #7 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/src/Renderer.php(195): Dompdf\Renderer->render(Object(Dompdf\FrameDecorator\TableCell))
    #8 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/src/Renderer.php(195): Dompdf\Renderer->render(Object(Dompdf\FrameDecorator\TableRow))
    #9 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/src/Renderer.php(195): Dompdf\Renderer->render(Object(Dompdf\FrameDecorator\TableRowGroup))
    #10 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/src/Renderer.php(195): Dompdf\Renderer->render(Object(Dompdf\FrameDecorator\Table))
    #11 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/src/FrameReflower/Page.php(149): Dompdf\Renderer->render(Object(Dompdf\FrameDecorator\Block))
    #12 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/src/FrameDecorator/AbstractFrameDecorator.php(913): Dompdf\FrameReflower\Page->reflow(NULL)
    #13 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/vendor/dompdf/dompdf/src/Dompdf.php(765): Dompdf\FrameDecorator\AbstractFrameDecorator->reflow()
    #14 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/includes/class-wcpdf-pdf-maker.php(52): Dompdf\Dompdf->render()
    #15 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/includes/documents/abstract-wcpdf-order-document.php(799): WPO\WC\PDF_Invoices\PDF_Maker->output()
    #16 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/includes/documents/abstract-wcpdf-order-document.php(864): WPO\WC\PDF_Invoices\Documents\Order_Document->get_pdf()
    #17 /home/***/***/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/includes/class-wcpdf-main.php(401): WPO\WC\PDF_Invoices\Documents\Order_Document->output_pdf('inline')
    #18 /home/***/***/wp-includes/class-wp-hook.php(308): WPO\WC\PDF_Invoices\Main->generate_pdf_ajax('')
    #19 /home/***/***/wp-includes/class-wp-hook.php(332): WP_Hook->apply_filters('', Array)
    #20 /home/***/***/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
    #21 /home/***/***/wp-admin/admin-ajax.php(188): do_action('wp_ajax_generat...')
    #22 {main}

    Let me just add, it was working till Today normally without any issues.

    • This topic was modified 2 years ago by KovaZg.
    • This topic was modified 2 years ago by KovaZg.
    • This topic was modified 2 years ago by KovaZg.
Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Contributor Yordan Soares

    (@yordansoares)

    Hi @kovazg,

    Could you send us a screenshot of your?System Configuration?and?Write Permissions, that you’ll find under?WooCommerce > PDF Invoices > Status?tab?

    You can upload the screenshot to imgbb.com, and then copy & paste the image URL in your reply here.

    Thread Starter KovaZg

    (@kovazg)

    Hello @yordansoares
    Here is link, I have tried to increase WP Memory Limit, but I was not successful, did it in cPanel, did it in wp-config and .htaccess

    https://ibb.co/ZdSq0Rq

    • This reply was modified 2 years ago by KovaZg.
    Thread Starter KovaZg

    (@kovazg)

    I removed checkamark in Cpanel for gmagick and put checkamark on imagick.

    In the system report it says:
    IMagick 3.7.0

    Now it works.

    Hi @kovazg,

    Could you confirm if the issue was resolved?

    Thread Starter KovaZg

    (@kovazg)

    If I had to use gmagick for some reason, issue would still be there. But yes, you can close this topic as resolved, I hope it helps someone.

    Plugin Contributor Yordan Soares

    (@yordansoares)

    Thanks for sharing the screenshot, and explaining how you fixed it!

    It’s likely that the issue with Gmagick is related due to a custom build in your server. Some hosting providers build their own PHP extensions, but sometimes this causes issues likes the one you reported.

    Anyway, I’m glad to hear that you managed to make it work ??

    By the way, if you don’t mind and have the time, do you think you could leave us a review?

    Thanks in advance and all the best with your store!

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Cannot generate invoice: “Error trying to generate document”’ is closed to new replies.