Created
February 7, 2018 17:12
-
-
Save luizbills/fff7aeb5dff802acb88d7a697e21aa0b to your computer and use it in GitHub Desktop.
Mudar resposta do correios de "Entrega em" para "Entrega em até"
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
| add_filter( 'woocommerce_package_rates', 'lpb_change_correios_shipping_response_label', 10, 2 ); | |
| function lpb_change_correios_shipping_response_label ( $rates, $package ) { | |
| foreach ( $rates as $rate) { | |
| if ( false !== strpos($rate->id, 'correios') ) { | |
| $rate->label = str_replace( 'Entrega em', 'Entrega em até', $rate->label ); | |
| } | |
| } | |
| return $rates; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment