Skip to content

Instantly share code, notes, and snippets.

@Sanabria
Forked from tavomak/ChangeLabelWooCheckout.php
Created December 20, 2017 03:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Sanabria/0c2f66e355ffaa03a2ca3e273e1a5920 to your computer and use it in GitHub Desktop.
Save Sanabria/0c2f66e355ffaa03a2ca3e273e1a5920 to your computer and use it in GitHub Desktop.
Cambiar Los encabezados del checkout de woocommerce
//Detalles de facturación
function wc_billing_field_strings( $translated_text, $text, $domain ) {
switch ( $translated_text ) {
case 'Detalles de facturación' :
$translated_text = __( 'Nuevo Encabezado', 'woocommerce' );
break;
}
return $translated_text;
}
add_filter( 'gettext', 'wc_billing_field_strings', 20, 3 );
//Otra dirección de envio
function wc_shipping_field_strings( $translated_text, $text, $domain ) {
switch ( $translated_text ) {
case '¿Enviar a una dirección diferente?' :
$translated_text = __( 'Nuevo Encabezado', 'woocommerce' );
break;
}
return $translated_text;
}
add_filter( 'gettext', 'wc_shipping_field_strings', 20, 3 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment