diff options
| author | Greg Roach <fisharebest@webtrees.net> | 2018-10-12 11:04:12 +0100 |
|---|---|---|
| committer | Greg Roach <fisharebest@webtrees.net> | 2018-10-12 11:15:32 +0100 |
| commit | dd6b2bfcc550270bb6d6778e11576148f71e4330 (patch) | |
| tree | 9462a8eabe1103a0e79c18c521b6b4858a3fb2dc /resources/views/modules/upcoming_events/list.phtml | |
| parent | afb591d7c8a3029b0ca03e6d185cacca3c22eb5f (diff) | |
| download | webtrees-dd6b2bfcc550270bb6d6778e11576148f71e4330.tar.gz webtrees-dd6b2bfcc550270bb6d6778e11576148f71e4330.tar.bz2 webtrees-dd6b2bfcc550270bb6d6778e11576148f71e4330.zip | |
Use .phtml extension for template files
Diffstat (limited to 'resources/views/modules/upcoming_events/list.phtml')
| -rw-r--r-- | resources/views/modules/upcoming_events/list.phtml | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/resources/views/modules/upcoming_events/list.phtml b/resources/views/modules/upcoming_events/list.phtml new file mode 100644 index 0000000000..f5b89e5d39 --- /dev/null +++ b/resources/views/modules/upcoming_events/list.phtml @@ -0,0 +1,19 @@ +<?php use Fisharebest\Webtrees\I18N; ?> +<?php use Fisharebest\Webtrees\Individual; ?> + +<?php foreach ($facts as $fact) : ?> + <?php $record = $fact->getParent(); ?> + <a href="<?= e($record->url()) ?>" class="list_item name2"> + <?= $record->getFullName() ?> + </a> + <?php if ($record instanceof Individual) : ?> + <?= $record->getSexImage() ?> + <?php endif ?> + <div class="indent"> + <?= $fact->getLabel() . ' — ' . $fact->getDate()->display(true); ?> + <?= ' (' . I18N::timeAgo($fact->anniv * 365 * 24 * 60 * 60) . ')'; ?> + <?php if (!$fact->getPlace()->isEmpty()) : ?> + <?= ' — <a href="' . $fact->getPlace()->getURL() . '">' . $fact->getPlace()->getFullName() . '</a>'; ?> + <?php endif ?> + </div> +<?php endforeach ?> |
