class_mcLanguage.inc.php 747 Bytes
<?php
class mcLanguage {
	private static $Language = 'deu';
	private static $Words = array(
		'deu' => array(
		)
	);
	public static function setLanguage($param_Language, array $param_LanguageTranslationArray=null) {
		if(array_key_exists($param_Language, self::$Words) && is_null($param_LanguageTranslationArray)) {
			self::$Language = $param_Language;
			
		} else if(is_array($param_LanguageTranslationArray)) {
			self::$Language = $param_Language;
			self::$Words[self::$Language] = $param_LanguageTranslationArray;

		}
	}
	public static function getWord($param_Word) {
		if(array_key_exists($param_Word, self::$Words[self::$Language])) {
			return self::$Words[self::$Language][$param_Word];
		} else {
			return $param_Word;
		}
	}
}

?>