Skip to content

Instantly share code, notes, and snippets.

@jesseeproductions
Created December 23, 2014 14:41
Show Gist options
  • Select an option

  • Save jesseeproductions/48897101078d0ee74e69 to your computer and use it in GitHub Desktop.

Select an option

Save jesseeproductions/48897101078d0ee74e69 to your computer and use it in GitHub Desktop.
Translate Add to Cart in WooCommerce Tickets
/*
* Translate Add to Cart in WooCommerce Tickets
* @version 3.9
*
*/
function woocommcere_tickets_filter_translations($translations, $text, $domain) {
if ($domain == 'tribe-wootickets') {
$text = str_ireplace( 'Add to cart', 'Add to cart(Translate)', $text );
}
return $text;
}
add_filter('gettext', 'woocommcere_tickets_filter_translations', 10, 3);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment