Title: leonwp's Replies | WordPress.org

---

# leonwp

  [  ](https://wordpress.org/support/users/leonwp/)

 *   [Profile](https://wordpress.org/support/users/leonwp/)
 *   [Topics Started](https://wordpress.org/support/users/leonwp/topics/)
 *   [Replies Created](https://wordpress.org/support/users/leonwp/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/leonwp/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/leonwp/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/leonwp/engagements/)
 *   [Favorites](https://wordpress.org/support/users/leonwp/favorites/)

 Search replies:

## Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)

 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Print Invoice & Delivery Notes for WooCommerce] Add Metadata to the PDF](https://wordpress.org/support/topic/add-metadata-to-the-pdf/)
 *  [leonwp](https://wordpress.org/support/users/leonwp/)
 * (@leonwp)
 * [14 hours, 12 minutes ago](https://wordpress.org/support/topic/add-metadata-to-the-pdf/#post-18905930)
 * Thanks for getting back anjitha21. For anyone else struggling with the new templates,
   here’s some more code that might be useful:
 *     ```wp-block-code
       $order_object = wc_get_order($order['id']); //order data objectecho $order_object->get_meta('My Custom Field'); //custom checkout fieldecho $order_object->get_used_coupons(); //coupons used
       ```
   
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Print Invoice & Delivery Notes for WooCommerce] Add Metadata to the PDF](https://wordpress.org/support/topic/add-metadata-to-the-pdf/)
 *  [leonwp](https://wordpress.org/support/users/leonwp/)
 * (@leonwp)
 * [1 day, 10 hours ago](https://wordpress.org/support/topic/add-metadata-to-the-pdf/#post-18905045)
 * Hi anjitha21,
 * do you have an example showing how to use `**wc_get_order( $order['id'] )**`?
 * E.g. showing coupon use or a custom checkout field?

Viewing 2 replies - 1 through 2 (of 2 total)