Skip to content
Snippets Groups Projects

Implement 5.1 WDN Template

3 files
+ 21
15
Compare changes
  • Side-by-side
  • Inline

Files

+ 5
5
@@ -38,7 +38,7 @@ $isEmbed = isset($_GET['embed']) && $_GET['embed'];
// While the site proper is skinned with a specific version, the templates used
// used in embed search need to be supported in legacy sites.
// ?embed=1 : 4.1
// ?embed=5.0 : 5.0
// ?embed=(not 1) : 5.1
if ($isEmbed && $_GET['embed'] === '1') {
$pageTemplate = 'Fixed';
$page = Templates::factory($pageTemplate, Templates::VERSION_4_1);
@@ -46,12 +46,12 @@ if ($isEmbed && $_GET['embed'] === '1') {
$page->addStyleSheet('css/search.css?v=20180901');
} else {
$pageTemplate = 'App';
$page = Templates::factory($pageTemplate, Templates::VERSION_5);
$pageTemplate = 'AppLocal';
$page = Templates::factory($pageTemplate, Templates::VERSION_5_1);
$templatePath = 'templates/5.0/';
if (!$isEmbed) {
if (file_exists(__DIR__ . '/wdn/templates_5.0')) {
if (file_exists(__DIR__ . '/wdn/templates_5.1')) {
$page->setLocalIncludePath(__DIR__);
}
@@ -59,7 +59,7 @@ if ($isEmbed && $_GET['embed'] === '1') {
$page->head .= '<link rel="home" href="./" />';
// Add WDN Deprecated Styles
$page->head .= '<link rel="preload" href="https://unlcms.unl.edu/wdn/templates_5.0/css/deprecated.css" as="style" onload="this.onload=null;this.rel=\'stylesheet\'"> <noscript><link rel="stylesheet" href="https://unlcms.unl.edu/wdn/templates_5.0/css/deprecated.css"></noscript>';
$page->head .= '<link rel="preload" href="/wdn/templates_5.1/css/deprecated.css" as="style" onload="this.onload=null;this.rel=\'stylesheet\'"> <noscript><link rel="stylesheet" href="/wdn/templates_5.1/css/deprecated.css"></noscript>';
// no menu items, so hide mobile menu
Loading