1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-05-06 15:45:34 +02:00

Failed to switch to English images default if prefered language doesn't exist ...

git-svn-id: file:///svn/phpbb/trunk@2212 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Paul S. Owen 2002-02-25 14:59:01 +00:00
parent f9dfbf2040
commit 22b9be70a4

View File

@ -301,12 +301,11 @@ function setup_style($style)
message_die(CRITICAL_ERROR, "Couldn't open $template_name template config file");
}
if ( file_exists($current_template_path . '/images/lang_' . $board_config['default_lang']) )
$img_lang = ( file_exists($current_template_path . '/images/lang_' . $board_config['default_lang']) ) ? $board_config['default_lang'] : 'english';
while( list($key, $value) = @each($images) )
{
while( list($key, $value) = @each($images) )
{
$images[$key] = str_replace("{LANG}", 'lang_' . $board_config['default_lang'], $value);
}
$images[$key] = str_replace("{LANG}", 'lang_' . $img_lang, $value);
}
}