|
From: Bill F. <fe...@re...> - 2002-11-30 21:19:50
|
In case there are words that get forgotten or are left untranslated in
a given language.inc.php, what do you think about always including
english.inc.php first? The other language.inc.php will overwrite
all the definitions for the translations that it knows about, and
the english ones will be left for the ones that are untranslated.
The diff is like:
--- functions/init.inc.php 19 Nov 2002 05:46:02 -0000 1.26
+++ functions/init.inc.php 30 Nov 2002 21:15:04 -0000
@@ -25,6 +25,10 @@
$language = strtolower($language);
$lang_file = BASE.'/languages/'.$language.'.inc.php';
+// english is always the most complete, so include it first and
+// let the other languages override the ones they know.
+include(BASE.'/languages/english.inc.php');
+
if (file_exists($lang_file)) {
include($lang_file);
} else {
This is unnecessary overhead in the preferred case (i.e. when the
translations are complete), but is potentially better than printing
empty strings for untranslated phrases if something gets overlooked.
What do you think?
Bill
|