From bd247e04b2ea42cac8eabdb43bd3cef8a7a25f2b Mon Sep 17 00:00:00 2001 From: Steve Sutton Date: Fri, 6 Mar 2015 09:19:18 -0500 Subject: [PATCH] move the fonts into Toolkit_Page class so we can set https or http --- Toolkit/Page.php | 10 ++++++++-- templates/template.html | 4 ---- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/Toolkit/Page.php b/Toolkit/Page.php index c25bb2c..ec0a823 100755 --- a/Toolkit/Page.php +++ b/Toolkit/Page.php @@ -146,7 +146,13 @@ class Toolkit_Page : BASE_URL . 'index.php'; // Resources needed for every page. - $GLOBALS['styleSheets'] = array(); + $baseFontUrl = ($_SERVER['HTTPS'] == 'on') ? 'https;//': 'http://'; + $GLOBALS['styleSheets'] = array( + $baseFontUrl . 'fonts.googleapis.com/css?family=Oleo+Script:400,700', + $baseFontUrl . 'fonts.googleapis.com/css?family=Oleo+Script+Swash+Caps:400,700', + $baseFontUrl . 'fonts.googleapis.com/css?family=Josefin+Slab:400,700', + $baseFontUrl . 'fonts.googleapis.com/css?family=Open+Sans:400,400italic,700', + ); // Resources needed for every page. $GLOBALS['topScripts'][] = MEDIA_BASE_URL . 'js/modernizr/modernizr.js'; $GLOBALS['bottomScripts'][] = JQUERY_CDN_JS; @@ -798,7 +804,7 @@ class Toolkit_Page $tabs = str_repeat($tab, $level * 2); $mainClass = ($className) ? ' class="'.$className.'"': ''; $result = "{$tabs}\n"; - if ($level >= 1) { + if ($level == 1) { $result .= '
  • '; } foreach ($array as $i => $node) { diff --git a/templates/template.html b/templates/template.html index b344009..e79d5c7 100755 --- a/templates/template.html +++ b/templates/template.html @@ -17,10 +17,6 @@ {pageTitle:h} {styles:h} - - - - {topScripts:h}