If this is given an order of [dk, za, fr_CA] a request for en_UK will
be looked up in en_UK, en, dk, za, fr_CA, fr before trying the default
locale.
If strict flag is given in the array, the above example would instead look
in en_UK, dk, za, fr_CA before trying the default locale. In other words,
the implicit fallback is not applied to the locales in the fallback rule.
Here is an example:
array('strict' => FALSE, 'order' => array('dk', 'za'))
public setFallbackRule ( array $fallbackRule ) | ||
$fallbackRule | array |
/** * Initializes the locale service * * @return void */ public function initializeObject() { $this->configuration = new Configuration($this->settings['defaultLocale']); $this->configuration->setFallbackRule($this->settings['fallbackRule']); if ($this->cache->has('availableLocales')) { $this->localeCollection = $this->cache->get('availableLocales'); } else { $this->generateAvailableLocalesCollectionByScanningFilesystem(); $this->cache->set('availableLocales', $this->localeCollection); } }