Skip to content

Instantly share code, notes, and snippets.

@MindyPostoff
Created January 30, 2015 22:30
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save MindyPostoff/7fdb43fce328049de1b9 to your computer and use it in GitHub Desktop.
Save MindyPostoff/7fdb43fce328049de1b9 to your computer and use it in GitHub Desktop.
Using Bookings to Sell Limited Products Daily
/** Add this function to your theme's functions.php file
* to replace the "Persons" string in the Bookings form
* to be "Number of Loaves".
*/
function my_text_strings( $translated_text, $text, $domain ) {
switch ( $translated_text ) {
case 'Persons' :
$translated_text = __( 'Number of Loaves', 'woocommerce-bookings' );
break;
}
return $translated_text;
}
add_filter( 'gettext', 'my_text_strings', 20, 3 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment