Translation
-
Hello, i have translate the clean-testimonials.po file. And rename it in fr-FR.po (and .mo)
But… what can i change here :
* Load language files * * @since 1.5.1 * * @return void */ public function load_textdomain() { // Set filter for plugin's languages directory $lang_dir = plugin_dir_path( __FILE__ ) . 'languages/'; // Traditional WordPress plugin locale filter $locale = apply_filters( 'plugin_locale', get_locale(), 'clean-testimonials' ); $mofile = sprintf( '%1$s-%2$s.mo', 'clean-testimonials', $locale ); // Setup paths to current locale file $mofile_local = $lang_dir . $mofile; $mofile_global = WP_LANG_DIR . '/clean-testimonials/' . $mofile; if ( file_exists( $mofile_global ) ) { load_textdomain( 'clean-testimonials', $mofile_global ); } elseif ( file_exists( $mofile_local ) ) { load_textdomain( 'clean-testimonials', $mofile_local ); } else { // Load the default language files load_plugin_textdomain( 'clean-testimonials', false, $lang_dir );
[Moderator Note: Please post code & markup between backticks or use the code button. Your posted code may now have been permanently damaged by the forum’s parser.]
Thank for your help…
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Translation’ is closed to new replies.