Skip to main content
Breakdance4fun Logo

Disable Breakdance Translations and Keep the Builder in English

Starting with Breakdance V3, the user interface and settings can be translated. Two translations are currently available: French and Brazilian Portuguese.

This means that if your WordPress site is set to French, Breakdance will automatically display in French as well. However, if you prefer to keep Breakdance in its original English version, you can use the PHP snippets below to disable the translation.

To do this, use a snippet manager such as WPCodeBox and add the following PHP code:

<?php
/**
* Keep Breakdance in English, regardless of WordPress locale.
*/
add_filter( 'override_load_textdomain', function( $override, $domain, $mofile ) {
$breakdance_domains = [
'breakdance',
'breakdance-builder',
'breakdance-elements',
];
if ( in_array( $domain, $breakdance_domains, true ) ) {
return true;
}
return $override;
}, 10, 3 );
/**
* Also disable JavaScript translations.
*/
add_filter( 'load_script_translation_file', function( $file, $handle, $domain ) {
$breakdance_domains = [
'breakdance',
'breakdance-builder',
'breakdance-elements',
];
if ( in_array( $domain, $breakdance_domains, true ) ) {
return false;
}
return $file;
}, 10, 3 );