Support » Plugin: Codestyling Localization » Translation of cNews theme in wrong folder

  • Resolved Lea


    When running CSL on cNews theme, CSL puts the translation files in the cnews/functions/lang/ folder, but that’s not the location the theme reads from. The theme reads from cnews/languages folder, as defined in its functions.php file:

    load_theme_textdomain('csc-themewp', get_template_directory() . '/languages');
    I can understand where CSL gets its notion about the functions/lang folder - somewhere else in the theme there is a definition:

    load_theme_textdomain(‘csc-themewp’, RWMB_DIR . ‘lang’);

    But why does CSL prefer this definition? It’s not the correct one, and that means that I can’t use CSL for translation of this theme 🙁

    Thanks for a wonderful plugin!

Viewing 1 replies (of 1 total)
  • Plugin Author codestyling


    Because this folder comes first during the dir scan and contains at least one *.mo/*.po or *.pot file. Because CSL can’t analyse the path because it’s created by function call and not by a constant, the only chance is to take that folder containing translation files.
    If there are 2 of them (whatoever reason?) the first found will win.

Viewing 1 replies (of 1 total)
  • The topic ‘Translation of cNews theme in wrong folder’ is closed to new replies.