Booster
4.6/5

Home Forums Booster Plus Customer Forum Odd issue with PDF invoicing

Tagged: 

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #55985
    Jan
    Participant

    Hi team,

    We have an issue with PDF Invoicing where on one order the PDF that generated had no data and couldn’t be opened. Deleting the invoice and regenerating did not fix the issue. We have over 100 other orders that haven’t been a problem. The issue was first detected when the client when to bulk export the PDF invoices from orders, and the broken PDF caused a critical error:

    Error Details
    =============
    An error of type E_ERROR was caused in line 423 of the file /home/1443740.cloudwaysapps.com/ttvshggcxs/public_html/wp-content/plugins/booster-plus-for-woocommerce/includes/class-wcj-pdf-invoicing.php. Error message: Uncaught ValueError: ZipArchive::addFile(): Argument #1 ($filepath) cannot be empty in /public_html/wp-content/plugins/booster-plus-for-woocommerce/includes/class-wcj-pdf-invoicing.php:423
    Stack trace:
    #0 /public_html/wp-content/plugins/booster-plus-for-woocommerce/includes/class-wcj-pdf-invoicing.php(423): ZipArchive->addFile()
    #1 /public_html/wp-content/plugins/booster-plus-for-woocommerce/includes/class-wcj-pdf-invoicing.php(308): WCJ_PDF_Invoicing->get_invoices_zip()
    #2 /public_html/wp-includes/class-wp-hook.php(324): WCJ_PDF_Invoicing->bulk_actions_handle()
    #3 /public_html/wp-includes/plugin.php(205): WP_Hook->apply_filters()
    #4 /public_html/wp-content/plugins/woocommerce/src/Internal/Admin/Orders/ListTable.php(1380): apply_filters()
    #5 /public_html/wp-content/plugins/woocommerce/src/Internal/Admin/Orders/PageController.php(318): Automattic\WooCommerce\Internal\Admin\Orders\ListTable->handle_bulk_actions()
    #6 /public_html/wp-content/plugins/woocommerce/src/Internal/Admin/Orders/PageController.php(166): Automattic\WooCommerce\Internal\Admin\Orders\PageController->setup_action_list_orders()
    #7 /public_html/wp-includes/class-wp-hook.php(324): Automattic\WooCommerce\Internal\Admin\Orders\PageController->handle_load_page_action()
    #8 /public_html/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters()
    #9 /public_html/wp-includes/plugin.php(517): WP_Hook->do_action()
    #10 /public_html/wp-admin/admin.php(238): do_action()
    #11 {main}
    thrown

    Aside from the usual culprits (plugin conflicts, etc), what should I be looking for? Since this site will be generating quite a few orders, I’d like to get ahead of this issue before it becomes a regular problem.

    #55987
    David G
    Participant

    Hello @janetrosehenry,

    Thank you for reaching out to us.

    PDF invoices cannot be opened properly on some servers due to an error log conflict. So added below code on you wp-config.php. The query plugin also follows this method. that’s why it was working when you activate it.

    @ini_set( ‘log_errors’, ‘On’ );
    @ini_set( ‘display_errors’, ‘Off’ );
    define( ‘WP_DEBUG’, true );
    define( ‘WP_DEBUG_LOG’, true );
    define( ‘WP_DEBUG_DISPLAY’, false );

    #55989
    Jaroslav Boháč
    Participant

    I’ve already addressed this here, with no answer. And I’m paying for the license. It just doesn’t work. This is what happens:

    🙂 I can’t upload it, your security plugin is blocking me.

    It’s quite specific. Can you help?

    #55990
    Jaroslav Boháč
    Participant

    One more addition – the invoice is sent correctly by email. However, it cannot be downloaded from WooCommerce or FTP – either a fatal error or a corrupted file.

    #55992
    Jan
    Participant

    Hi David,

    In staging the invoice generates successfully, even without adding that code to the wp-config.php file. When I add that code to the wp-config.php file on the live site, it still doesn’t work on that one order.

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.