Created
February 13, 2023 12:05
-
-
Save Niloys7/4a3e2f0df7b46148ad968f085a8be310 to your computer and use it in GitHub Desktop.
Add Content in custom status email template
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* How to edit or override the email templates for custom order status? | |
* @link https://brightplugins.com/docs/how-to-edit-or-override-the-email-templates-for-custom-order-status/ | |
*/ | |
add_action( 'woocommerce_email_before_order_table', 'brightplugins_add_content_specific_email', 20, 4 ); | |
function brightplugins_add_content_specific_email( $order, $sent_to_admin, $plain_text, $email ) { | |
if ( $email->id == 'bvos_custom_transit' ) { | |
echo '<p>Content for Transit Status</p>'; | |
} | |
if ( $email->id == 'bvos_custom_waiting-for-conf' ) { | |
echo '<p>Content for Waiting Status</p>'; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment