Arc-hive-omeka-theme/view/omeka/site/page/show.phtml

107 lines
2.4 KiB
PHTML

<?php
$this->htmlElement('body')->appendAttribute('class', 'page ' . $page->slug());
$this->pageTitle($page->title(), 2);
$showPagePagination = $this->siteSetting('show_page_pagination', true);
?>
<!-- arc-hive insert begins -->
<?php
//$site->pages();
$img_src = $this->getHelperPluginManager()->get('headerImage')->getImage($page);
if (!$img_src) {
$img_src = '/themes/archive/asset/img/default-header-image.jpg';
}
if ($this->site->title() == "Collections") {
$image_height = "300px";
} else {
$image_height = "200px";
}
?>
<style>
#archive_header_img {
background: url("<?= $img_src ?>") no-repeat;
width: 100%;
height: <?= $image_height ?>;
}
</style>
<script>
<?php
$_html = '<a href="'.$this->site->url().'">'.$this->site->title().'</a>';
?>
$("#archive_page_title").html('<?php echo $_html ?>');
</script>
<!-- arc-hive insert ends -->
<?php /*
echo $page->id();
$this->pageTitle($page->title());
*/
?>
<?php
$nav = $site->publicNav();
$container = $nav->getContainer();
$activePage = $nav->findActive($container);
if ($activePage):
?>
<?php if ($activePage['depth'] !== 0): ?>
<nav class="breadcrumbs">
<?php echo $nav->breadcrumbs()->setPartial('common/foundation-breadcrumbs'); ?>
</nav>
<?php endif; ?>
<?php endif; ?>
<!--
<?php
$pages = $this->getHelperPluginManager()->get('archiveSiteMeta')->getPages('exhibit');
foreach ($pages as $key => $value) {
print($key);
print('<br />');
print("--".$value."--");
print('<br />');
}
?>
-->
<!-- archive menu -->
<?php
/*
echo $this->partial('common/search-form');
echo $nav->menu()->renderSubMenu();
*/
?>
<?php if ($activePage): ?>
<?php if ($this->displayNavigation && $activePage['page']->hasPages()): ?>
<nav class="sub-menu wide" data-sticky-container>
<div class="sticky" data-sticky data-anchor="blocks">
<?php echo $nav->menu()->setUlClass('vertical menu')->renderSubMenu(); ?>
</div>
</nav>
<?php endif; ?>
<?php endif; ?>
<?php $this->trigger('view.show.before'); ?>
<div id="blocks" class="blocks">
<?php echo $this->content; ?>
</div>
<?php if ($this->site->title() != "Collections") { ?>
<button class="end_of_page_button" onclick="window.location.href = '/'">
Collection index
</button>
<?php } ?>
<?php $this->trigger('view.show.after'); ?>
<?php /* if ($showPagePagination): */ ?>
<?php if (1 == 0): ?>
<?php echo $this->sitePagePagination(); ?>
<?php endif; ?>