Created
May 14, 2018 07:42
-
-
Save Steeru/f44c9ce7e347816872c015ae524d9684 to your computer and use it in GitHub Desktop.
This file contains 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
function wp_travel_custom_gettext_string_editor( $string ){ | |
switch ($string) { | |
case '%s Day(s) %s Night(s)': | |
return '%s Hour(s) %s Minute(s)'; | |
break; | |
case 'Day(s)' : | |
return 'Hour(s)'; | |
break; | |
case 'Night(s)' : | |
return 'Minute(s)'; | |
break; | |
case 'Day(s):' : | |
return 'Hour(s):'; | |
break; | |
case 'Night(s):' : | |
return 'Minute(s):'; | |
break; | |
} | |
return $string; | |
} | |
add_filter( 'gettext', 'wp_travel_custom_gettext_string_editor', 30 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment