Hi @nickfr,
I’m afraid we don’t have the integration with Polylang. Polylang seems doesn’t have the feature to translate the Wholesale Price text because the data is from the options data/database and its string translation has certain limitations.
We have integration with the WPML plugin and it is easily translatable with their plugin. I’d suggest you use this plugin instead.
Thread Starter
nickfr
(@nickfr)
I guess is same for premium version?
I would suggest to change at least this text to use po files if possible.
CUrrently this stops us from moving to premium
Wpml apart from its cost it is too heavy for a site.
-
This reply was modified 4 years ago by nickfr.
Hi @nickfr,
I just finished checking the Polylang documentation and it seems that we can override it with a custom snippet:
add_filter( ‘wwp_filter_wholesale_price_title_text’ , function( $wholesale_price_text ) {
// error_log(get_user_locale());
switch( pll_current_language() ) {
case ‘fr’: // change this to other language code
return ‘Prix de gros’; //your translation for this language
default:
return $wholesale_price_text;
}
} , 10 , 1 );
You just need to change the ‘fr’ to your desire language code. You can check it here: https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes