Created
April 15, 2016 15:40
-
-
Save matt-h/8a8029425252f30cf0a517eff923d673 to your computer and use it in GitHub Desktop.
woocommerce email replacement string
This file contains 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
<?php | |
function woocommerce_email_format_string_find( $find, $email ) { | |
$find['customer_info'] = '{customer_info}'; | |
return $find; | |
} | |
add_filter( 'woocommerce_email_format_string_find', 'woocommerce_email_format_string_find', 10, 2 ); | |
function woocommerce_email_format_string_replace( $replace, $email ) { | |
$replace['customer_info'] = 'replacement string'; | |
return $replace; | |
} | |
add_filter( 'woocommerce_email_format_string_replace', 'woocommerce_email_format_string_find', 10, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment