From 183851b06bd6c52f3cae5375f433da720d410447 Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Wed, 11 Oct 2006 18:12:39 +0000 Subject: MediaWiki 1.7.1 wiederhergestellt --- languages/LanguageNah.php | 52 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 languages/LanguageNah.php (limited to 'languages/LanguageNah.php') diff --git a/languages/LanguageNah.php b/languages/LanguageNah.php new file mode 100644 index 00000000..d29a53e2 --- /dev/null +++ b/languages/LanguageNah.php @@ -0,0 +1,52 @@ + + * + * @copyright Copyright © 2006, Rob Church + * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later + */ + +require_once( 'LanguageEs.php' ); + +if (!$wgCachedMessageArrays) { + require_once('MessagesNah.php'); +} + +# Per conversation with a user in IRC, we inherit from Spanish and work from there +# Nahuatl was the language of the Aztecs, and a modern speaker is most likely to +# understand Spanish if a Nah translation is not available + +class LanguageNah extends LanguageEs { + private $mMessagesNah = null; + + function __construct() { + parent::__construct(); + + global $wgAllMessagesNah; + $this->mMessagesNah =& $wgAllMessagesNah; + + } + + function getFallbackLanguage() { + return 'es'; + } + + function getMessage( $key ) { + if( isset( $this->mMessagesNah[$key] ) ) { + return $this->mMessagesNah[$key]; + } else { + return parent::getMessage( $key ); + } + } + + function getAllMessages() { + return $this->mMessagesNah; + } + +} + +?> \ No newline at end of file -- cgit v1.2.3-54-g00ecf