adds image header to item page

This commit is contained in:
buttle 2021-05-17 22:18:06 +02:00
parent 136e495aee
commit 18e68ce308
1 changed files with 25 additions and 3 deletions

View File

@ -7,6 +7,28 @@ $itemMedia = $item->media();
$showLayout = $this->themeSetting('show_layout'); $showLayout = $this->themeSetting('show_layout');
?> ?>
<?php
$site->pages();
// set header image
$img_src = $this->getHelperPluginManager()->get('archiveSiteMeta')->getSiteImage($site);
if ($img_src) {
?>
<style>
#archive_header_img {
background:url("<?= $img_src ?>") no-repeat;
width:100%;
height:100px;
}
</style>
<?php } else { ?>
<style>
#archive_header_img {
display: none;
}
</style>
<?php } ?>
<div class="resource-title"> <div class="resource-title">
<?php echo $this->pageTitle($item->displayTitle(), 2); ?> <?php echo $this->pageTitle($item->displayTitle(), 2); ?>
<h3 class="label"><?php echo $translate('Item'); ?></h3> <h3 class="label"><?php echo $translate('Item'); ?></h3>