mirror of
https://github.com/wavelog/wavelog.git
synced 2026-03-22 10:24:14 +00:00
add to use english language if ask not found
add to use the english language file, if the ask language not found
This commit is contained in:
@@ -146,8 +146,22 @@ class CI_Lang {
|
||||
break;
|
||||
}
|
||||
}
|
||||
// try to load in default language (english) //
|
||||
if (($found !== TRUE)&&($idiom != 'english')) {
|
||||
$idiom = 'english';
|
||||
foreach (get_instance()->load->get_package_paths(TRUE) as $package_path)
|
||||
{
|
||||
$package_path .= 'language/'.$idiom.'/'.$langfile;
|
||||
if ($basepath !== $package_path && file_exists($package_path))
|
||||
{
|
||||
include($package_path);
|
||||
$found = TRUE;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if ($found !== TRUE)
|
||||
{
|
||||
show_error('Unable to load the requested language file: language/'.$idiom.'/'.$langfile);
|
||||
|
||||
Reference in New Issue
Block a user