From 29a418fd39ecb3fcec4cee0ed83644e217dfdb1b Mon Sep 17 00:00:00 2001 From: "NeatElves@gmail.com" Date: Sun, 1 May 2011 10:42:12 +0000 Subject: [PATCH] =?utf8?q?=D0=9F=D0=BE=D0=BA=D0=B0=D0=B7=20=D0=B0=D0=BA?= =?utf8?q?=D1=82=D0=B8=D0=B2=D0=BD=D1=8B=D1=85=20=D1=81=D0=BE=D0=B1=D1=8B?= =?utf8?q?=D1=82=D0=B8=D0=B9=20=D1=82=D0=BE=D0=BB=D1=8C=D0=BA=D0=BE=20?= =?utf8?q?=D0=BF=D0=BE=20=D1=85=D0=BE=D0=BB=D0=B8=D0=B4=D0=B5=D0=B9=5F?= =?utf8?q?=D0=B8=D0=B4.)?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit git-svn-id: http://cswowd-fork.googlecode.com/svn/trunk@106 e451fad0-63ce-11de-bed1-e3a98b22654c --- include/functions.php | 7 +++++++ lang/lang.en.php | 2 +- lang/lang.ru.php | 4 ++-- module/online/online.php | 10 +++++++--- 4 files changed, 17 insertions(+), 6 deletions(-) diff --git a/include/functions.php b/include/functions.php index ff1d97b..9f05069 100644 --- a/include/functions.php +++ b/include/functions.php @@ -1007,6 +1007,13 @@ function getGameEventActive() return $cDB->select("SELECT `event` FROM `game_event_status`"); } +function getGameEventActiveName($event_id) +{ + global $dDB; + return $dDB->selectCell("-- CACHE: 1h + SELECT `holiday` FROM `game_event` WHERE `entry` = ?d", $event_id); +} + function getGameHolidayName($holiday_id) { global $dDB; diff --git a/lang/lang.en.php b/lang/lang.en.php index 7d85409..8aec695 100644 --- a/lang/lang.en.php +++ b/lang/lang.en.php @@ -504,7 +504,7 @@ $lang = array( 'stat_online' => 'Online:', 'stat_classes' => 'Class statistic', 'stat_races' => 'Race statistic', -'stat_timers' => 'Timers & event:', +'stat_timers' => 'Timers:', 'ap_date' => 'Date of scoring arena:', 'daily_quest_date' => 'Date reset daily quests:', 'weekly_quest_date' => 'Date reset weekly quests:', diff --git a/lang/lang.ru.php b/lang/lang.ru.php index 15498a7..389bbfb 100644 --- a/lang/lang.ru.php +++ b/lang/lang.ru.php @@ -507,12 +507,12 @@ $lang = array( 'stat_online' => 'Онлайн:', 'stat_classes' => 'Статистика по классам', 'stat_races' => 'Статистика по расам', -'stat_timers' => 'Таймеры и события:', +'stat_timers' => 'Таймеры:', 'ap_date' => 'Дата начисления очков арены:', 'daily_quest_date' => 'Дата сброса ежедневных квестов:', 'weekly_quest_date' => 'Дата сброса еженедельных квестов:', 'monthly_quest_date' => 'Дата сброса ежемесячных квестов:', -'active_event' => 'Активное событие:', +'active_event' => 'Активные события:', # Main menu 'main'=>'Главная', diff --git a/module/online/online.php b/module/online/online.php index 6715967..01cd292 100644 --- a/module/online/online.php +++ b/module/online/online.php @@ -76,9 +76,13 @@ else echo "".$lang['weekly_quest_date']."".$weekly_quest_date.""; echo "".$lang['monthly_quest_date']."".$monthly_quest_date.""; if ($s = getGameEventActive()) - foreach ($s as $s1) - { - echo "".$lang['active_event']."".getGameEventName($s1['event']).""; +{ + echo "".$lang['active_event'].""; + foreach ($s as $s1) + { + if (getGameEventActiveName($s1['event'])) + echo "".getGameEventName($s1['event']).""; + } } echo ""; -- 2.11.4.GIT