Files
opensourcepos/application/libraries/MY_Language.php
objecttothis b75fe4b8d2 Not sure if this was removed after download or not. Should it be merged?
git-svn-id: svn+ssh://jekkos@svn.code.sf.net/p/opensourcepos/code/@67 c3eb156b-1dc0-44e1-88ae-e38439141b53
2013-07-05 20:13:09 +00:00

27 lines
537 B
PHP

<?php
class MY_Language extends Lang
{
function MY_Language()
{
parent::Lang();
}
function switch_to( $idiom )
{
$CI =& get_instance();
if( is_string( $idiom ) )
{
$CI->config->set_item( 'language', $idiom );
$loaded = $this->is_loaded;
$this->is_loaded = array();
foreach($loaded as $file)
{
$this->load( str_replace( '_lang.php', '', $file ) );
}
}
}
}
?>