Wednesday 18 January 2012 4:22:48 pm
Hi,
We made a new handler, ezcreatelanguage.php, for creating new languages. It was working fine, until we deleted the cache directories:
rm -Rf var/cache var/.../cache
Then, the new languages disappeared, from the backend, therefore in the ezcontent_language table.
XML:
<?xml version="1.0" encoding="UTF-8"?> <eZXMLImporter> <CreateLanguage> <languages> <language locale="My first language" /> <language locale="My second language" /> </languages> </CreateLanguage> </eZXMLImporter>
PHP:
$languages = $xml->getElementsByTagName('language'); foreach ( $languages as $language ) { $locale = $language->getAttribute('locale'); $lang = eZContentLanguage::fetchByLocale($locale, TRUE); }
I don't know the reason, in lib/ezlocale/classes/ezlocale.php, we fetch the languages from the cache, I guess there is one.
Can someone help me please, thanks!
Jean-Luc.
You must be logged in to post messages in this topic!