| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180 |
- <?php
- $logo = "/img/logo.png";
- $icon = "/img/icon.png";
- if(!PRODUCTION) {
- $logo = "/img/dev_logo.png";
- $icon = "/img/dev_icon.png";
- }
- $body_class = "";
- $print = http::value("print");
- if($print) $body_class = "print";
- ?>
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="utf-8" />
- <meta http-equiv="x-ua-compatible" content="ie=edge" />
- <meta name="viewport" content="width=device-width, initial-scale=1.0" />
- <title><?=htmlspecialchars($page_title)?> | <?=htmlspecialchars(APP_NAME)?></title>
- <meta property="og:site_name" content="<?=htmlspecialchars(APP_NAME)?>" />
- <meta property="og:title" content="<?=htmlspecialchars($page_title)?>" />
- <meta property="og:description" content="<?=htmlspecialchars(__("Age Verification Testing and Training across the UK"))?>" />
- <meta property="og:type" content="website" />
- <meta property="og:image" content="<?=PROTOCOL?>://<?=DOMAIN?>/img/logo.png" />
- <meta property="og:image:alt" content="Check Policy logo" />
- <meta property="og:url" content="<?=PROTOCOL?>://<?=DOMAIN?><?=htmlspecialchars($_SERVER["REQUEST_URI"])?>" />
- <link href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700" rel="stylesheet" />
- <link rel="stylesheet" href="/css/bootstrap.min.css?<?=filemtime("public/css/bootstrap.min.css")?>" />
- <link rel="icon" href="<?=$icon?>?<?=filemtime("public" . $icon)?>" />
- <script type="text/javascript" src="/js/fontawesome-all.min.js?<?=filemtime("public/js/fontawesome-all.min.js")?>"></script>
- <?php
- if(GOOGLE_ANALYTICS_ID) {
- ?>
- <!-- Global site tag (gtag.js) - Google Analytics -->
- <script async src="https://www.googletagmanager.com/gtag/js?id=<?=GOOGLE_ANALYTICS_ID?>"></script>
- <script>
- window.dataLayer = window.dataLayer || [];
- function gtag(){dataLayer.push(arguments);}
- gtag('js', new Date());
- gtag('config', '<?=GOOGLE_ANALYTICS_ID?>');
- </script>
- <?php
- }
- ?>
- </head>
- <body class="<?=htmlspecialchars($body_class)?>">
- <div class="fixed-top d-print-none" style="overflow-y: auto; max-height: 100%;">
- <nav class="navbar navbar-expand-lg navbar-light bg-light">
- <div class="navbar-brand p-0">
- <a href="/">
- <img src="<?=$logo?>?<?=filemtime("public" . $logo)?>" style="height: 40px;" />
- </a>
- </div>
- <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbar-content" aria-controls="navbar-content" aria-expanded="false" aria-label="Toggle navigation">
- <span class="navbar-toggler-icon"></span>
- </button>
- <div class="collapse navbar-collapse" id="navbar-content">
- <ul class="navbar-nav ml-auto">
- <?php
- if(!Core::isLoggedIn()) {
- ?>
- <li class="nav-item">
- <a class="nav-link" href="/services"><?=htmlspecialchars(__("Services"))?></a>
- </li>
- <li class="nav-item">
- <a class="nav-link" href="/become-a-tester"><?=htmlspecialchars(__("Become a Tester"))?></a>
- </li>
- <?php
- }
- ?>
- <li class="nav-item">
- <a class="nav-link" href="/contact"><?=htmlspecialchars(__("Contact"))?></a>
- </li>
- <?php
- if(Core::isLoggedIn()) {
- ?>
- <li class="nav-item">
- <a class="nav-link" href="/account"><?=htmlspecialchars(__("Account"))?></a>
- </li>
- <li class="nav-item">
- <a class="nav-link" href="/log-out"><?=htmlspecialchars(__("Log Out"))?></a>
- </li>
- <?php
- }
- else {
- ?>
- <li class="nav-item">
- <a class="nav-link" href="/jobs"><?=htmlspecialchars(__("Jobs"))?></a>
- </li>
- <li class="nav-item">
- <a class="nav-link" href="/register"><?=htmlspecialchars(__("Register"))?></a>
- </li>
- <li class="nav-item">
- <a class="nav-link" href="/log-in"><?=htmlspecialchars(__("Log In"))?></a>
- </li>
- <?php
- }
- ?>
- </ul>
- </div>
- </nav>
- </div>
- <?php
- if(count(Core::$breadcrumbs) > 1) {
- View::include("breadcrumbs");
- }
- if(!PRODUCTION) {
- $style = (count(Core::$breadcrumbs) > 1) ? "margin-top: -1rem;" : "";
- ?>
- <div class="p-2 mb-3 bg-danger text-white text-center d-print-none" style="<?=$style?>">
- <strong><?=htmlspecialchars(__("PLEASE NOTE:"))?></strong> <?=htmlspecialchars(__("This is a development version of the site."))?>
- </div>
- <?php
- }
- if(Core::$show_alerts) {
- $alerts = Core::getAlerts();
- if($alerts) {
- ?>
- <div class="container">
- <?php
- foreach($alerts as $alert) {
- list($class, $message) = $alert;
- $icon = "info-circle";
- if($class == "success") $icon = "check";
- if($class == "warning") $icon = "exclamation-triangle";
- if($class == "error") $icon = "exclamation-circle";
- ?>
- <div class="alert alert-<?=$class?> alert-dismissable fade show">
- <button type="button" class="close" data-dismiss="alert" aria-label="Close">
- <span aria-hidden="true">×</span>
- </button>
- <i class="fal fa-fw fa-<?=$icon?>"></i> <?=htmlspecialchars($message)?>
- </div>
- <?php
- }
- ?>
- </div>
- <?php
- }
- }
- if(!Core::$cookie_alert_shown) {
- ?>
- <div class="container mt-3">
- <div class="alert alert-info alert-dismissable fade show">
- <button type="button" class="close" data-dismiss="alert" aria-label="Close">
- <span aria-hidden="true">×</span>
- </button>
- <div class="row">
- <div class="col-auto pr-0">
- <i class="fal fa-fw fa-info-circle"></i>
- </div>
- <div class="col">
- <strong><?=htmlspecialchars(__("This site uses cookies to improve functionality and personalisation."))?></strong><br />
- <?=htmlspecialchars(__("By continuing to use the site, you consent to our use of cookies and our privacy policy."))?>
- </div>
- </div>
- </div>
- </div>
- <?php
- }
- ?>
|