first commit
This commit is contained in:
42
autoload/language/class.Language.php
Normal file
42
autoload/language/class.Language.php
Normal file
@@ -0,0 +1,42 @@
|
||||
<?php
|
||||
namespace language;
|
||||
|
||||
class Language {
|
||||
|
||||
private $_translation;
|
||||
private $_language;
|
||||
|
||||
public function __construct( $var )
|
||||
{
|
||||
$this -> _language = $var;
|
||||
}
|
||||
|
||||
public function get_language()
|
||||
{
|
||||
return $this->_language;
|
||||
}
|
||||
|
||||
public function set_language($_language)
|
||||
{
|
||||
$this->_language = $_language;
|
||||
}
|
||||
|
||||
public function get_translation()
|
||||
{
|
||||
return $this->_translation;
|
||||
}
|
||||
|
||||
public function set_translation($_translation)
|
||||
{
|
||||
$this->_translation = $_translation;
|
||||
}
|
||||
|
||||
public function getTrans( $val )
|
||||
{
|
||||
if ( isset( $this -> _translation[ $val ] ) )
|
||||
return $this -> _translation[ $val ];
|
||||
else
|
||||
return $val;
|
||||
}
|
||||
}
|
||||
?>
|
||||
Reference in New Issue
Block a user