/** * set a new locale from i18n */ function setNewLocale($category = LC_ALL) { global $NEWLCOALE; setOldLocale(); $NEWLOCALE = setCustomLocale(getLocaleConfig(), $category); return $NEWLOCALE; }
/** * Global Language Data * * @global (array) $i18n i18n token keyed translation array * @global (str) $LANG IETF langcode (w/underscore delim) [tag]_[subtag] */ global $i18n, $LANG; // load language $LANG = getDefaultLang(); // set global language from config heirarchy i18n_merge(null); // load $LANG file into $i18n i18n_mergeDefault(); // load GSDEFAULTLANG or GSMERGELANG lang into $i18n to override ugly missing {} tokens if set //save php locale setOldLocale(); /** * Globals for salt and authentication data * * @global (obj) $dataa, authorization xml raw obj from GSDATAOTHERPATH.GSAUTHFILE * @global (str) $SALT, salt from gsconfig else authorization file * @global (str) $SESSIONHASH used for stateless session confirmation, or as non-expiring nonce for certain operations */ global $dataa, $SALT, $SESSIONHASH; // grab authorization and security data fatal fail if salt is not set $SALT = getDefaultSalt(); if (!isset($SALT) && $SITEURL != '' && notInInstall()) { die(i18n_r('KILL_CANT_CONTINUE') . "<br/>" . sprintf(i18n_r('NOT_SET'), 'SALT')); } $SESSIONHASH = sha1($SALT . $SITENAME); /**