diff options
Diffstat (limited to 'views/elements')
-rw-r--r-- | views/elements/animetable.html.php | 6 | ||||
-rw-r--r-- | views/elements/mangatable.html.php | 29 |
2 files changed, 32 insertions, 3 deletions
diff --git a/views/elements/animetable.html.php b/views/elements/animetable.html.php index 0d9f9fb..ea222a6 100644 --- a/views/elements/animetable.html.php +++ b/views/elements/animetable.html.php @@ -6,12 +6,12 @@ <tr> <td> <a href="/anime/view/<?= $a->special_id ?>"><?= $a->title ?></a> - <?php if ($a->foreign_titles || $a->alternative_titles): ?> + <?php if (isset($a->foreign_titles) || isset($a->alternative_titles)): ?> <span class="alt_titles"> - <?php if ($a->foreign_titles): ?> + <?php if (isset($a->foreign_titles)): ?> <?= $a->foreign_titles[0] ?> <?php endif ?> - <?php if ($a->alternative_titles): ?> + <?php if (isset($a->alternative_titles)): ?> <?= $a->alternative_titles[0] ?> <?php endif ?> diff --git a/views/elements/mangatable.html.php b/views/elements/mangatable.html.php new file mode 100644 index 0000000..c92ff83 --- /dev/null +++ b/views/elements/mangatable.html.php @@ -0,0 +1,29 @@ +<table> +<th>Title</th> +<th>Date</th> +<th style="width: 200px">Type</th> +<?php foreach ($manga as $m): ?> + <tr> + <td> + <a href="/manga/view/<?= $m->special_id ?>"><?= $m->title ?></a> + <?php if (isset($m->foreign_titles) || isset($m->alternative_titles)): ?> + <span class="alt_titles"> + <?php if (isset($m->foreign_titles)): ?> + <?= $m->foreign_titles[0] ?> + <?php endif ?> + <?php if (isset($m->alternative_titles)): ?> + + <?= $m->alternative_titles[0] ?> + <?php endif ?> + </span> + <?php endif ?> + </td> + <td> + <?= $m->publish_period ?> + </td> + <td> + <?= $m->author ?> + </td> + </tr> +<?php endforeach ?> +</table> |