(bug #3655) fix news language detection

This patch improve the language detection for news in opac. If the user have no defined language in his browser.
Mergefix
This commit is contained in:
Nahuel ANGELINETTI 2009-09-23 14:56:44 +02:00 committed by Henri-Damien LAURENT
parent 677111b342
commit a72500e239

View file

@ -48,9 +48,6 @@ $template->param(
# display news
# use cookie setting for language, bug default to syspref if it's not set
<<<<<<< HEAD:opac/opac-main.pl
my $news_lang = $input->cookie('KohaOpacLanguage') || 'en';
=======
(my $theme) = themelanguage(C4::Context->config('opachtdocs'),'opac-main.tmpl','opac',$input);
my $translations = getTranslatedLanguages('opac',$theme);
@ -77,7 +74,6 @@ if($input->cookie('KohaOpacLanguage')){
$news_lang = $news_lang ? $news_lang : 'en' ;
>>>>>>> e25ac14... (bug #3655) fix news language detection:opac/opac-main.pl
my $all_koha_news = &GetNewsToDisplay($news_lang);
my $koha_news_count = scalar @$all_koha_news;