1<?php use Fisharebest\Webtrees\Auth; ?> 2<?php use Fisharebest\Webtrees\DebugBar; ?> 3<?php use Fisharebest\Webtrees\FlashMessages; ?> 4<?php use Fisharebest\Webtrees\I18N; ?> 5<?php use Fisharebest\Webtrees\Theme; ?> 6<?php use Fisharebest\Webtrees\View; ?> 7 8<!DOCTYPE html> 9<html <?= I18N::htmlAttributes() ?>> 10 <head> 11 <meta charset="UTF-8"> 12 <meta name="csrf" content="<?= e(csrf_token()) ?>"> 13 <meta name="viewport" content="width=device-width, initial-scale=1"> 14 <meta name="robots" content="<?= e($meta_robots ?? 'noindex,nofollow') ?>"> 15 <meta name="generator" content="<?= e(WT_WEBTREES) ?>"> 16 <?php if ($tree !== null) : ?> 17 <meta name="description" content="<?= e($tree->getPreference('META_DESCRIPTION')) ?>"> 18 <?php endif ?> 19 20 <title> 21 <?= strip_tags($title) ?> 22 <?php if ($tree !== null && $tree->getPreference('META_TITLE') !== '') : ?> 23 – <?= e($tree->getPreference('META_TITLE')) ?> 24 <?php endif ?> 25 </title> 26 27 <link rel="icon" href="<?= Theme::theme()::ASSET_DIR ?>favicon.png" type="image/png"> 28 <link rel="icon" type="image/png" href="<?= Theme::theme()::ASSET_DIR ?>favicon192.png" sizes="192x192"> 29 <link rel="apple-touch-icon" sizes="180x180" href="<?= Theme::theme()::ASSET_DIR ?>favicon180.png"> 30 31 <?php if (I18N::direction() === 'rtl') : ?> 32 <link rel="stylesheet" type="text/css" href="<?= e(WT_ASSETS_URL . 'css/vendor-rtl.css') ?>"> 33 <?php else : ?> 34 <link rel="stylesheet" type="text/css" href="<?= e(WT_ASSETS_URL . 'css/vendor.css') ?>"> 35 <?php endif ?> 36 37 <?php foreach (Theme::theme()->stylesheets() as $stylesheet) : ?> 38 <link rel="stylesheet" type="text/css" href="<?= $stylesheet ?>"> 39 <?php endforeach ?> 40 41 <?= View::stack('styles') ?> 42 43 <?= Theme::theme()->analytics() ?> 44 45 <?= DebugBar::renderHead() ?> 46 </head> 47 48 <body class="wt-global"> 49 <header class="wt-header-wrapper d-print-none"> 50 <div class="container wt-header-container"> 51 <div class="row wt-header-content"> 52 <div class="wt-accessibility-links"> 53 <a class="sr-only sr-only-focusable btn btn-info btn-sm" href="#content"> 54 <?= /* I18N: Skip over the headers and menus, to the main content of the page */ I18N::translate('Skip to content') ?> 55 </a> 56 </div> 57 <div class="col wt-site-logo"></div> 58 59 <?php if ($tree !== null) : ?> 60 <h1 class="col wt-site-title"><?= e($tree->title()) ?></h1> 61 62 <div class="col wt-header-search"> 63 <form class="wt-header-search-form" role="search"> 64 <input type="hidden" name="route" value="search-quick"> 65 <input type="hidden" name="ged" value="<?= e($tree->name()) ?>"> 66 <div class="input-group"> 67 <label class="sr-only" for="quick-search"><?= I18N::translate('Search') ?></label> 68 <input type="search" class="form-control wt-header-search-field" id="quick-search" name="query" size="15" placeholder="<?= I18N::translate('Search') ?>"> 69 <span class="input-group-btn"> 70 <button type="submit" class="btn btn-primary wt-header-search-button"> 71 <?= view('icons/search') ?> 72 </button> 73 </span> 74 </div> 75 </form> 76 </div> 77 <?php endif ?> 78 79 <div class="col wt-secondary-navigation"> 80 <ul class="nav wt-secondary-menu"> 81 <?php foreach (Theme::theme()->secondaryMenu() as $menu) : ?> 82 <?= $menu->bootstrap4() ?> 83 <?php endforeach ?> 84 </ul> 85 </div> 86 87 <?php if ($tree !== null) : ?> 88 <nav class="col wt-primary-navigation"> 89 <ul class="nav wt-primary-menu"> 90 <?php foreach (Theme::theme()->primaryMenu($individual ?? $tree->significantIndividual(Auth::user())) as $menu) : ?> 91 <?= $menu->bootstrap4() ?> 92 <?php endforeach ?> 93 </ul> 94 </nav> 95 <?php endif ?> 96 </div> 97 </div> 98 </header> 99 100 <main id="content" class="wt-main-wrapper"> 101 <div class="container wt-main-container"> 102 <div class="flash-messages"> 103 <?php foreach (FlashMessages::getMessages() as $message) : ?> 104 <div class="alert alert-<?= e($message->status) ?> alert-dismissible" role="alert"> 105 <button type="button" class="close" data-dismiss="alert" aria-label="<?= I18N::translate('close') ?>"> 106 <span aria-hidden="true">×</span> 107 </button> 108 <?= $message->text ?> 109 </div> 110 <?php endforeach ?> 111 </div> 112 113 <?= $content ?> 114 </div> 115 </main> 116 117 <footer class="wt-footer-container"> 118 <div class="wt-footer-content container d-print-none"> 119 <?= Theme::theme()->formatContactLinks() ?> 120 <?= Theme::theme()->logoPoweredBy() ?> 121 122 <?php if ($page_hits ?? 0 > 0) : ?> 123 <div class="wt-page-views"> 124 <?= I18N::plural( 125 'This page has been viewed %s time.', 126 'This page has been viewed %s times.', 127 $page_hits, 128 '<span class="odometer">' . I18N::digits($page_hits) . '</span>' 129 ) ?> 130 </div> 131 <?php endif ?> 132 133 <?= Theme::theme()->cookieWarning()?> 134 </div> 135 </footer> 136 137 <script src="<?= e(WT_ASSETS_URL . 'js/vendor.js') ?>?<?= filemtime(WT_ROOT . WT_ASSETS_URL . 'js/vendor.js') ?>"></script> 138 <script src="<?= e(WT_ASSETS_URL . 'js/webtrees.js') ?>?<?= filemtime(WT_ROOT . WT_ASSETS_URL . 'js/webtrees.js') ?>"></script> 139 140 <script> 141 activate_colorbox(); 142 jQuery.extend(jQuery.colorbox.settings, { 143 width: "85%", 144 height: "85%", 145 transition: "none", 146 slideshowStart: "<?= I18N::translate('Play') ?>", 147 slideshowStop: "<?= I18N::translate('Stop') ?>", 148 title: function() { return this.dataset.title; } 149 }); 150 </script> 151 152 <?= View::stack('javascript') ?> 153 154 <?= DebugBar::render() ?> 155 </body> 156</html> 157