Customizing translations through a child-theme

Hi,

I’ve been using your Activello theme to great effect for our Dutch magazine site: http://www.tijdschriftskut.nl/

The default theme was customized using a child-theme. Now I want to polish the site by translating the last remnants of English into Dutch. I am using poedit to modify the nl_NL.po file. And I put the new files (both .mo and .po) in “child-theme/languages/” folder. However nothing actually happens.

I also tried putting:
“load_child_theme_textdomain( ‘activello’, get_template_directory() . ‘/languages’ );”

into the child theme functions.php. but nothing actually happens.

Is there something else i am supposed to do? I am kinda at a loss. the .mo and .po files are named nl_NL.

Hi @seikopath,

I hope you are well today and thank you for your question.

Please try adding the following code in the functions.php file of your child theme.

function custom_activello_setup() {

  /*
   * Make theme available for translation.
   * Translations can be filed in the /languages/ directory.
   */
  load_theme_textdomain( 'activello', get_stylesheet_directory() . '/languages' );

}
add_action( 'after_setup_theme', 'custom_activello_setup', 99 );

Make sure you have saved the translation files in the languages directory of your child theme and follow the instructions provided on the below page.

Best Regards,
Movin

Hi Movin,

Thanks for your response! It works perfectly now.
I’ll get to translating.

Have a nice day!
YF

You are most welcome here :slight_smile: