diff options
| author | David Siegfried <ds.siegfried@gmail.com> | 2021-11-08 12:03:29 +0100 |
|---|---|---|
| committer | Jan-Hendrik Willms <tleilax+studip@gmail.com> | 2021-11-08 11:08:54 +0000 |
| commit | bb721983c4ae98114f73da9cf5e0ccbf4fb1cffd (patch) | |
| tree | 408548f7d9ef9131a4ec6a34181cf2f2846fb572 /templates/dates | |
| parent | 04dd489ca1d93293adbabfe35d58b8bebe03c57f (diff) | |
prevent warnings, refs #399
Diffstat (limited to 'templates/dates')
| -rw-r--r-- | templates/dates/seminar_html_roomplanning.php | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/templates/dates/seminar_html_roomplanning.php b/templates/dates/seminar_html_roomplanning.php index f331149..f95ccbb 100644 --- a/templates/dates/seminar_html_roomplanning.php +++ b/templates/dates/seminar_html_roomplanning.php @@ -1,7 +1,7 @@ <? if (!isset($show_room)) : // show rooms only if there is more than one - if (empty($dates['rooms']) || sizeof($dates['rooms']) === 1) : + if (empty($dates['rooms']) || count($dates['rooms']) === 1) : $show_room = false; else : $show_room = true; @@ -50,12 +50,12 @@ if (!empty($dates['regular']['turnus_data']) || !empty($dates['irregular'])) : endif; endforeach; unset($irregular_rooms['']); - echo sizeof($output) ? ", <br>" : ''; + echo count($output) ? ", <br>" : ''; - $rooms = array_merge(getPlainRooms($irregular_rooms, false), array_keys($freetext_rooms)); + $rooms = array_merge(getPlainRooms($irregular_rooms), array_keys($freetext_rooms)); - if (is_array($irregular) && sizeof($irregular)) : - if (isset($shrink) && !$shrink && sizeof($irregular < 20)) : + if (is_array($irregular) && count($irregular)) : + if (isset($shrink) && !$shrink && count($irregular) < 20) : foreach ($irregular as $date) : echo $date['tostring']; @@ -69,9 +69,9 @@ if (!empty($dates['regular']['turnus_data']) || !empty($dates['irregular'])) : endforeach; else : echo _("Termine am") . implode(', ', shrink_dates($irregular)); - if (is_array($rooms) && sizeof($rooms) > 0) : - if (sizeof($rooms) > 3) : - $rooms = array_slice($rooms, sizeof($rooms) - 3, sizeof($rooms)); + if (is_array($rooms) && count($rooms) > 0) : + if (count($rooms) > 3) : + $rooms = array_slice($rooms, count($rooms) - 3, count($rooms)); endif; if ($show_room) : |
