×

Notice

The forum is in read only mode.
Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC: Languages with no locale are not generated

Languages with no locale are not generated 10 years 11 months ago #20361

  • Jeremy Magne
  • Jeremy Magne's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 2
  • Thank you received: 0
Hi,

I noticed that languages without locale were not generated. Of course, I could have added language translations to the config like en:en, es:es, fr:fr...

I figured that a simple change in the code could ease this and auto accept languages without locale
so in file /administrator/components/com_ctransifex/helpers/transifex.php
class ctransifexHelperTransifex
{
    [...]
 
    public static function getJLangCode($transifexLang, $projectConfig){
 
 
        $languages = self::getLangmap($projectConfig);
 
	/***********************/
	/* CUSTOM CODE - START */
        /* Auto accept languages with no locale (en, fr, es...) */
	/***********************/
	if (strlen($transifexLang) == 2) {
		$languages[strtolower($transifexLang)] = strtolower($transifexLang);
	}
	/***********************/
	/* CUSTOM CODE - END   */
	/***********************/
 
        [...]
    }
 
    [...]
}

Languages with no locale are not generated 10 years 11 months ago #20368

  • Paulo Pereira
  • Paulo Pereira's Avatar
  • Offline
  • Junior Boarder
  • Junior Boarder
  • Posts: 27
  • Thank you received: 1
agree with that feature but only if this would be an option... I want an option to not download all languages and for now it would be done by not mapping it!! :)

Languages with no locale are not generated 10 years 9 months ago #21334

  • Daniel Dimitrov
  • Daniel Dimitrov's Avatar
  • Offline
  • Administrator
  • Administrator
  • Posts: 9618
  • Karma: 155
  • Thank you received: 1081
Okay, but what is the use to have en mapped to en? There is no such language pack in joomla? So installing those lang files won't bring anything.
  • Page:
  • 1
Time to create page: 0.138 seconds