Created
November 20, 2018 05:57
-
-
Save yousufansa/3184de4964b1eb23208d22beee32ae92 to your computer and use it in GitHub Desktop.
Jobhunt - Change Add to cart Button Text
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
if ( ! function_exists( 'jh_child_woocommerce_product_add_to_cart_text' ) ) { | |
function jh_child_woocommerce_product_add_to_cart_text( $text ) { | |
if ( $text == 'Add to cart' ) { | |
$text = esc_html__( 'Your Button Text', 'jobhunt' ); | |
} | |
return $text; | |
} | |
} | |
add_filter( 'woocommerce_product_add_to_cart_text', 'jh_child_woocommerce_product_add_to_cart_text' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment