1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-08 15:46:44 +02:00

Simplify import language definitions syntax for both core and 3rd party language files - introducing e107::coreLan() and e107::plugLan() (see new methods documentation)

This commit is contained in:
secretr
2010-10-31 14:50:40 +00:00
parent 5086e4709d
commit 9f298c46d1
2 changed files with 73 additions and 4 deletions

View File

@@ -522,14 +522,21 @@ if(varset($pref['multilanguage']) && (e_LANGUAGE != $pref['sitelanguage']))
$sql2->mySQLlanguage = e_LANGUAGE;
}
//TODO do it only once and with the proper function
e107_include_once(e_LANGUAGEDIR.e_LANGUAGE.'/'.e_LANGUAGE.'.php');
e107_include_once(e_LANGUAGEDIR.e_LANGUAGE."/".e_LANGUAGE.'_custom.php');
//do it only once and with the proper function
// e107_include_once(e_LANGUAGEDIR.e_LANGUAGE.'/'.e_LANGUAGE.'.php');
// e107_include_once(e_LANGUAGEDIR.e_LANGUAGE.'/'.e_LANGUAGE.'_custom.php');
include(e_LANGUAGEDIR.e_LANGUAGE.'/'.e_LANGUAGE.'.php'); // FASTEST - ALWAYS load
$customLan = e_LANGUAGEDIR.e_LANGUAGE.'/'.e_LANGUAGE.'_custom.php';
if(is_readable($customLan)) // FASTER - if exist, should be done 'once' by the core
{
include($customLan);
}
unset($customLan);
e107::getSession()
->challenge() // Create a unique challenge string for CHAP login
->check(); // Token protection
// echo e_print($_SESSION, e107::getSession()->getSessionId(), e107::getSession()->getSessionName());
//
// N: misc setups: online user tracking, cache
//