From d06f44761f746991d2219b41f713b669cde532ab Mon Sep 17 00:00:00 2001 From: Vasil Kolev Date: Tue, 20 Oct 2015 01:14:42 +0300 Subject: [PATCH] add legend --- page-schedule.php | 9 +++++++++ schedule/parse.php | 12 +++++++++++- 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/page-schedule.php b/page-schedule.php index 7e23a92..f3dc704 100644 --- a/page-schedule.php +++ b/page-schedule.php @@ -57,6 +57,15 @@ $content = require __DIR__ . DIRECTORY_SEPARATOR . 'schedule' . DIRECTORY_SEPARA
+ + + + +
$slot) { } $lines[] = ''; +/* create the legend */ + +$legend = []; + +foreach($data['tracks'] as $track) { + $legend[] = '' . $track['name'][$lang] . ''; +} +foreach (array('en' => 'English', 'bg' => 'Български') as $l => $n) { + $legend[] = '' . $n . ''; +} $gspk = []; $fspk = []; @@ -147,4 +157,4 @@ foreach ($data['speakers'] as $speaker) { $gspk[] = ''; -return array_merge($data, compact('lines', 'fulltalks', 'gspk', 'fspk')); +return array_merge($data, compact('lines', 'fulltalks', 'gspk', 'fspk', 'legend'));