add_filter( 'gettext', function( $translated_text, $text, $domain ) { switch ( $translated_text ) { case 'String 1' : $translated_text = esc_html__(…
function myprefix_live_site_locale( $locale ) { if ( ! is_admin() ) { return 'ru_RU'; // make front-end Russian } return $locale;…
// This is just an example...you will probably want to adjust to also check for the current page or other…
function my_child_theme_locale() { load_child_theme_textdomain( 'total', get_stylesheet_directory() . '/languages' ); } add_action( 'after_setup_theme', 'my_child_theme_locale' );