how to change go to shop button text in woocommerce

Solutions on MaxInterview for how to change go to shop button text in woocommerce by the best coders in the world

showing results for - "how to change go to shop button text in woocommerce"
Salvatore
15 Aug 2020
1add_filter( 'gettext', 'change_woocommerce_return_to_shop_text', 20, 3 );
2
3function change_woocommerce_return_to_shop_text( $translated_text, $text, $domain ) {
4
5        switch ( $translated_text ) {
6
7            case 'Go to the shop' :
8
9                $translated_text = __( 'Browse Shop', 'woocommerce' );
10                break;
11
12        }
13
14    return $translated_text;
15}