Support » Plugin: WooCommerce PDF Invoices & Packing Slips » Show Payment date

  • Resolved Nitrat


    Why I can’t deduce the payment date of the order in my template. such code does not work
    <strong><?php echo $order->get_meta('_date_completed'); ?>

Viewing 3 replies - 1 through 3 (of 3 total)
  • `<?php echo $order->get_meta(‘_date_completed’); ?>

    Plugin Author Ewout


    There are two options for this. With a custom template in the free version you can use this for the ‘paid date’:

    <?php echo $this->order->get_date_paid()->date_i18n( wc_date_format() ); ?>

    or this for the ‘completed’ date:

    <?php echo $this->order->get_date_completed()->date_i18n( wc_date_format() ); ?>

    With our Premium Templates extension you can do this without code, using a custom block with the {{date_paid}} or {{date_completed}} placeholder:

    Perfect! Thanks

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