Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- add_action( 'woocommerce_email_after_order_table', 'ts_email_after_order_table', 10, 4 );
- function ts_email_after_order_table( $order, $sent_to_admin, $plain_text, $email ) {
- if ( $order->has_status( 'completed' ) ) : ?>
- <p><?php printf( __( 'Hey %1$s. Thanks for shopping with us. As a way of saying thanks, here is your coupon code for your next purchase : %2$s' ), $order->get_billing_first_name(), '<strong>FLAT50</strong>' ); ?></p>
- <?php endif;
- }
Add Comment
Please, Sign In to add comment