--- a/includes/clientside/static/enano-lib-basic.js Tue Jun 24 23:37:23 2008 -0400
+++ b/includes/clientside/static/enano-lib-basic.js Thu Jun 26 16:56:52 2008 -0400
@@ -462,4 +462,12 @@
window[i] = placeholder_instances[i].go;
}
+$lang = {
+ get: function(a, b)
+ {
+ load_component('l10n');
+ return $lang.get(a, b);
+ }
+}
+
//*/
--- a/includes/clientside/static/l10n.js Tue Jun 24 23:37:23 2008 -0400
+++ b/includes/clientside/static/l10n.js Thu Jun 26 16:56:52 2008 -0400
@@ -4,15 +4,27 @@
var Language = function(lang_id)
{
- // load the language file
- load_show_win('strings');
- var ajax = ajaxMakeXHR();
- var uri = makeUrlNS('Special', 'LangExportJSON/' + lang_id);
- ajax.open('GET', uri, false);
- ajax.send(null);
- if ( ajax.readyState == 4 && ajax.status == 200 )
+ var have_lang = false;
+
+ if ( typeof(enano_lang) == 'object' )
+ {
+ if ( typeof(enano_lang[lang_id]) == 'object' )
+ {
+ have_lang = true;
+ }
+ }
+ if ( !have_lang )
{
- eval_global(ajax.responseText);
+ // load the language file
+ load_show_win('strings');
+ var ajax = ajaxMakeXHR();
+ var uri = makeUrlNS('Special', 'LangExportJSON/' + lang_id);
+ ajax.open('GET', uri, false);
+ ajax.send(null);
+ if ( ajax.readyState == 4 && ajax.status == 200 )
+ {
+ eval_global(ajax.responseText);
+ }
}
if ( typeof(enano_lang) != 'object' )
--- a/install/includes/stages/login.php Tue Jun 24 23:37:23 2008 -0400
+++ b/install/includes/stages/login.php Thu Jun 26 16:56:52 2008 -0400
@@ -155,6 +155,12 @@
return true;
}
+ addOnloadHook(function()
+ {
+ load_component('crypto');
+ load_component('l10n');
+ });
+
// ]]>
</script>
--- a/install/includes/ui.php Tue Jun 24 23:37:23 2008 -0400
+++ b/install/includes/ui.php Thu Jun 26 16:56:52 2008 -0400
@@ -173,6 +173,7 @@
var pagepass=\'\';
var ENANO_LANG_ID = 1;
var DISABLE_MCE = true;
+ var msg_loading_component = \'Loading %component%...\';
</script>';
echo <<<EOF
--- a/install/install.php Tue Jun 24 23:37:23 2008 -0400
+++ b/install/install.php Thu Jun 26 16:56:52 2008 -0400
@@ -18,7 +18,7 @@
define('IN_ENANO', 1);
// DEFINE THIS BEFORE RELEASE!
-define('ENANO_DANGEROUS', 1);
+// define('ENANO_DANGEROUS', 1);
require_once('includes/common.php');
@ini_set('display_errors', 'on');