WordPress action hook
woocommerce_email_before_order_table
Defined by WooCommerce and fired by 39 plugins in total, running on 7.9M+ sites between them.
“Action hook to add custom content before order details in email.”
How to use woocommerce_email_before_order_table
It's an action: your callback runs at that point and receives 4 arguments. Nothing needs to be returned.
Add this to your theme's functions.php or a small custom plugin:
add_action( 'woocommerce_email_before_order_table', function( $order, $sent_to_admin, $plain_text, $email ) {
// Your code runs here.
}, 10, 4 );Argument names come from WooCommerce's source. Other plugins may pass different values: check the call in the plugin you're targeting below.
39 plugins that fire woocommerce_email_before_order_table
Sorted by active installs. Each entry shows where the plugin calls the hook and what it passes.
-
WooCommerce7+ million installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )templates/emails/email-order-details.php:49 -
WooCommerce Stripe Payment Gateway700,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, false, $plain_text, $email )templates/emails/failed-preorder-authentication.php:32 -
Kadence WooCommerce Email Designer90,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, true, false )templates/wcmp/vendor-new-order.php:30 -
Custom Order Status Manager for WooCommerce30,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, true, false, $email )templates/emails/admin-order-status-email.php:17 -
Email Templates Customizer and Designer for WordPress and WooCommerce20,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, true, false )templates/wcmp/vendor-new-order.php:30 -
Mailonix20,000+ installs
do_action( 'woocommerce_email_before_order_table', $this->order, false, false, '' )includes/email-render.php:928 -
WCFM Marketplace10,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, true, false, $email )views/emails/plain/store-new-order.php:82 -
WebToffee eCommerce Marketing Automation10,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )includes/wt-woo-templates/emails/email-order-details.php:30 -
NP Quote Request for WooCommerce8,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )woocommerce/emails/admin-new-rfq.php:30 -
Donation Platform for WooCommerce: Fundraising & Donation Management6,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )includes/wc-templates/emails/email-order-details.php:53 -
Deposits & Partial Payments for WooCommerce5,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text )templates/emails/plain/customer-order-deposit-paid.php:12 -
Quotes for WooCommerce4,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )templates/emails/new-quote-request-sent-customer.php:37 -
WC Vendors3,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, true )templates/emails/notify-vendor-shipped.php:23 -
WP Crowdfunding2,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )woocommerce/emails/email-order-details.php:22 -
Order Approval for Woocommerce1,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, true, false, $email )templates/emails/plain/store-new-preorder.php:98 -
Partial Shipment for WooCommerce1,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )emails/email-partial-order-details.php:25 -
WP Hotel Booking WooCommerce1,000+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )templates/woocommerce/emails/email-order-details.php:22 -
Sublium Subscriptions700+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )templates/emails/order-items.php:23 -
MarketKing700+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )public/templates/email-order-details.php:97 -
PDF Invoice for WooCommerce + Drag and Drop Template Builder500+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )woocommerce/templates/emails/email-order-items.php:23 -
WooBooster Partial COD for WooCommerce400+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )templates/emails/email-order-details.php:42 -
Paguelofacil Checkout for Woocommerce300+ installs
do_action( 'woocommerce_email_before_order_table', 'add_order_email_instructions_lk', 10, 3 )class-gateway.php:571 -
Email Customizer for WooCommerce200+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )templates/order_items.php:18 -
Hotel Booking for WooCommerce100+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )templates/emails/email-booking-details.php:42 -
Split Pay100+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )wc-templates/emails/email-order-details.php:29 -
SDP Custom Order Status for WooCommerce100+ installs
do_action( 'woocommerce_email_before_order_table', $this->object, in_array ('admin', $this->notificaciones), $this->plain, $this )src/notificacion.php:206 -
MonstaManagement presents WebMonsta!70+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )templates/emails/custom-email-order-details.php:21 -
OpenPOS Lite60+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )templates/emails/email-order-details.php:22 -
Boopis WooCommerce RFQ60+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )templates/emails/email-quote-details.php:7 -
Email Templates Customizer for WooCommerce + Drag And Drop Template Builder40+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )woocommerce/shortcodes.php:568 -
Virfice30+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )src/Utils.php:678 -
Marketing 360® Payments for WooCommerce30+ installs
do_action( 'woocommerce_email_before_order_table', $order, false, $plain_text, $email )templates/emails/failed-preorder-authentication.php:30 -
CodesWholesale.com for WooCommerce10+ installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text )templates/emails/customer-completed-order.php:8 -
Zirkel Virtual IBAN for WooCommerceFewer than 10 installs
do_action( 'woocommerce_email_before_order_table', $order, false, false, $email )templates/emails/customer-awaiting-transfer.php:31 -
SaleSaverFewer than 10 installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )templates/emails/salesaver-pending-payment.php:34 -
Flowbyte Store BoosterFewer than 10 installs
do_action( 'woocommerce_email_before_order_table', null, false, false, $this )modules/back-in-stock/class-email.php:90 -
PayRivet Payments with Stripe for WooCommerceFewer than 10 installs
do_action( 'woocommerce_email_before_order_table', $order, false, $plain_text, $email )templates/emails/failed-preorder-authentication.php:33 -
AnticipoFewer than 10 installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, false, $email )templates/emails/anticipo-po-email.php:87 -
AAkron PersonalizationFewer than 10 installs
do_action( 'woocommerce_email_before_order_table', $order, $sent_to_admin, $plain_text, $email )admin/woocommerce/emails/email-order-details.php:21
Need a customisation built on this hook?
Tell us what you want to change and which plugin it's for. We'll write it, test it and send it back as a small plugin.