Reputation: 33
I use a free plugin to provide estimated delivery date for orders , the plugin have its shortcode to show the estimated time [display_ship_est], i need to output this shortcode to the default woocommerce notification emails . any help please , thanks in advance
Upvotes: 0
Views: 871
Reputation: 759
Use a hook like woocommerce_email_after_order_table
for exemple
add_action( "woocommerce_email_after_order_table", "custom_woocommerce_email_after_order_table", 10, 1);
function custom_woocommerce_email_after_order_table( $order ) {
echo 'Estimated delivery date is'. wse_shipping_est('', '', 0);
// or
echo do_shortcode( '[display_ship_est]' );
}
Upvotes: 2