Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {strip}
- {*
- * Template name: Bootstrap4 Core
- * -------------------------------------
- *
- * This is the main section of the regular templates. It inherits settings from the "Bootstrap4 Settings"
- * template and most basic customisations can be done there.
- *
- * Note: this template should not be set to "listable" nor should it be the "default" template in
- * CMSMS. Instead, either the "Bootstrap4 Triple Cols" or "Bootstrap4 Nonuple Cols" templates should
- * be used as the default as they both further extend this template.
- *
- * Part of the CMSMS Bootstrap4 template by stom | stom66.co.uk
- *}
- {process_pagedata}
- {$debug_mode=false scope=global}
- {***************** Area 1 [processed first] *****************}
- {block name='top'}
- {include file="cms_template:Bootstrap4 Settings"}
- {* Check for module availability *}
- {cge_have_module module='CGSmartImage' assign='mod_CGSmartImage'}
- {cge_have_module module='Markdown' assign='mod_Markdown'}
- {cge_have_module module='SitemapMgr' assign='mod_SitemapMgr'}
- {cge_have_module module='CGWebPush' assign='mod_CGWebPush'}
- {* Setup page content and attributes *}
- {$footer_js = "{content block='footer_js' label='Footer JavaScript' tab='zz_2logic_tab__'}" scope=global}
- {* I know this cludge is frowned upon. Don't tell Calguy. *}
- {$content1 = "{content tab='Content 1'}" scope=global}
- {$content1_style = "{content block='content1_style' label='Class' tab='Content 1' oneline='true'}"|default:"col-12" scope=global}
- {$content1_disable_markdown = "{content block='content1_disable_markdown' oneline='true' label='Content 1: Disable Markdown?' tab='Content 1'}" scope=global}
- {* I know this cludge is frowned upon. Don't tell Calguy. *}
- {$body_class = "{content block='body_class' label='Body class' oneline='true'}"|default:"" scope=global}
- {$container_class = "{content block='container_class' label='Container class' oneline='true'}"|default:"container" scope=global}
- {$row_class = "{content block='row_class' label='Row class' oneline='true'}"|default:"row" scope=global}
- {$meta_description = "{content block='meta-description' wysiwyg='false' oneline='true' label='Meta description' tab='Meta data'}" scope=global}
- {$meta_keywords = "{content block='meta-keywords' wysiwyg='false' oneline='true' label='Meta keywords' tab='Meta data'}" scope=global}
- {$page_description = $meta_description|default:$content1|markdown|strip_tags|strip|trim|truncate:180 scope=global}
- {$page_keywords = $meta_keywords|default:$my_keywords}
- {$canonical_url = $canonical_url|default:"{$content_obj->GetURL()|lower|default:''}" scope=global}
- {$page_breadcrumbs = $page_breadcrumbs|default:"{nav_breadcrumbs|strip|trim}" scope=global}
- {$page_image = $page_image|default:"{$default_image}" scope=global}
- {$page_lang = $page_lang|default:"{cms_get_language}" scope=global}
- {$page_modified = $page_modified|default:"{modified_date format='%Y-%m-%dT%T%z'}" scope=global}
- {$page_robots = $page_robots|default:"index,follow" scope=global}
- {$page_title = $page_title|default:"{title}" scope=global}
- {$page_type = $page_type|default:"website" scope=global}
- {$root_url = $root_url|default:"{root_url}" scope=global}
- {$site_name = $site_name|default:"{sitename}" scope=global}
- {* Set additional page classes *}
- {$navbar_classes = "navbar navbar-expand-sm"}
- {if $default_footer_style=="sticky"}
- {$body_class="{$body_class} sticky-footer"}{/if}
- {if !empty($navbar_color)}
- {$navbar_classes = "{$navbar_classes} navbar-{$navbar_color}"}{/if}
- {if !empty($navbar_background_color)}
- {$navbar_classes = "{$navbar_classes} bg-{$navbar_background_color}"}{/if}
- {if $default_navbar_style =="fixed"}
- {$navbar_classes = "{$navbar_classes} fixed-top"}{/if}
- {if $default_navbar_style =="default"}
- {$navbar_classes = "{$navbar_classes} rounded my-5"}{/if}
- {if $default_navbar_style =="top"}
- {$navbar_classes = "{$navbar_classes} mb-4"}{/if}
- {* Include the JS files used in the template.
- Locations assume installation via npm to /assets directory of the following modules:
- - jQuery@3.2.1
- - popover.js
- - bootstrap@4.0.0-beta.2
- - lightbox2
- *}
- {cgjs_require jsfile="assets/node_modules/jquery/dist/jquery.min.js"}
- {cgjs_require jsfile="assets/node_modules/popper.js/dist/umd/popper.min.js"}
- {cgjs_require jsfile="assets/node_modules/bootstrap/dist/js/bootstrap.min.js"}
- {cgjs_require jsfile="assets/node_modules/lightbox2/dist/js/lightbox.min.js"}
- {* End of "top" block *}
- {/block}
- {/strip}<!doctype html>
- <html lang="{$page_lang}"{if $default_footer_style=="sticky"} class="sticky-footer"{/if}>
- <head>{***************** Area 2 [processed third] *****************}
- <!-- Basic declarations -->
- <meta charset="utf-8">
- <meta http-equiv="x-ua-compatible" content="ie=edge">
- <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
- <title>{$page_title} - {$site_name}</title>
- <!-- Meta data -->
- <meta name="application-name" content="{$site_name}" />
- <meta name="author" content="{$author_name}" />
- <meta name="copyright" content="Copyright (C) {$author_name}, All Rights Reserved" />
- <meta name="description" content="{$page_description}" />
- <meta name="generator" content="CMS Made Simple - Copyright (C) 2004-{$smarty.now|date_format:'%Y'} CMSMS™. All rights reserved." />
- <meta name="keywords" content="{$page_keywords}" />
- <meta name="robots" content="{$page_robots}" />
- <!-- Open graph meta data -->
- <meta property="og:description" content="{$page_description}" />
- <meta property="og:image" content="{$page_image}" />
- <meta property="og:site_name" content="{$site_name}" />
- <meta property="og:title" content="{$page_title}" />
- <meta property="og:type" content="{$page_type}" />
- <meta property="og:updated_time" content="{$page_modified}" />
- <meta property="og:url" content="{$canonical_url}" />
- <!-- Twitter meta data -->
- <meta name="twitter:card" content="summary" />
- <meta name="twitter:creator" content="{$twitter_handle}" />
- <meta name="twitter:description" content="{$page_description}" />
- <meta name="twitter:domain" content="{root_url}" />
- <meta name="twitter:image" content="{$page_image}" />
- <meta name="twitter:site" content="{$site_name}" />
- <meta name="twitter:title" content="{$page_title}" />
- <meta name="twitter:url" content="{$canonical_url}" />
- <meta name="tweetmeme-title" content="{$page_title}" />
- {if !empty($google_site_key)}
- <!-- Google meta data -->
- <meta name="google-site-verification" content="{$google_site_key}" />
- {/if}
- {if (!empty($fb_app_id) && $fb_app_id > 0) || !empty($fb_admins)}
- <!-- Facebook meta data -->
- {if !empty($fb_app_id) && $fb_app_id > 0} <meta property="fb:app_id" content="{$fb_app_id}" />
- {/if}
- {if !empty($fb_admins)}<meta property="fb:admins" content="{$fb_admins}" />
- {/if}
- {/if}
- {if !empty($manifest_alias)}
- <!-- Web manifest -->
- <link rel="manifest" href="{root_url}/{$manifest_alias}">
- {/if}
- <!-- Stylesheets -->
- {cms_stylesheet|strip}
- <!-- HTML5 Shiv for IE -->
- <!--[if lt IE 9]>
- <script src="https://cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv.js"></script>
- <![endif]-->
- <!-- Favicons and app icons -->
- {if !empty($favicon_ico)} <link rel="shortcut icon" href="{$favicon_ico}" />
- {/if}
- {if $mod_CGSmartImage && !empty($favicon_png)}{* Check for CGSmartImage and print the various favicons *}
- <link rel="icon" type="image/png" sizes="196x196" href="{CGSmartImage src=$favicon_png notag=1 force_ext=1 noembed=1 filter_resizetofit='196,196,#ff000,126'}" />
- <link rel="icon" type="image/png" sizes="128x128" href="{CGSmartImage src=$favicon_png notag=1 force_ext=1 noembed=1 filter_resizetofit='128,128,#ff000,126'}" />
- <link rel="icon" type="image/png" sizes="16x16" href="{CGSmartImage src=$favicon_png notag=1 force_ext=1 noembed=1 filter_resizetofit='16,16,#ff000,126'}" />
- <link rel="icon" type="image/png" sizes="32x32" href="{CGSmartImage src=$favicon_png notag=1 force_ext=1 noembed=1 filter_resizetofit='32,32,#ff000,126'}" />
- <link rel="apple-touch-icon" href="{CGSmartImage src=$favicon_png notag=1 force_ext=1 noembed=1 filter_resizetofit='60,60,#ff000,126'}" />
- <link rel="apple-touch-icon" sizes="76x76" href="{CGSmartImage src=$favicon_png notag=1 force_ext=1 noembed=1 filter_resizetofit='76,76,#ff000,126'}" />
- <link rel="apple-touch-icon" sizes="120x120" href="{CGSmartImage src=$favicon_png notag=1 force_ext=1 noembed=1 filter_resizetofit='120,120,#ff000,126'}" />
- <link rel="apple-touch-icon" sizes="152x152" href="{CGSmartImage src=$favicon_png notag=1 force_ext=1 noembed=1 filter_resizetofit='152,152,#ff000,126'}" />
- <meta name="msapplication-TileImage" content="{CGSmartImage src=$favicon_png notag=1 noembed=1 force_ext=1 filter_resizetofit='144,144,#ff000,126'}" />
- {/if}
- <!-- User agent theme declarations -->
- <meta name="apple-mobile-web-app-capable" content="yes">
- <meta name="apple-mobile-web-app-status-bar-style" content="{$apple_mobile_style}">
- <meta name="msapplication-navbutton-color" content="{$theme_color}">
- <meta name="theme-color" content="{$theme_color}" />
- {if $mod_SitemapMgr}
- <!-- Link to sitemap -->
- <link rel="sitemap" type="application/xml" title="Sitemap" href="{root_url}/sitemap.xml" />
- {/if}
- <!-- Declare canonical URL -->
- <link rel="canonical" href="{$canonical_url}" />
- <!-- Other global meta data -->
- {metadata|strip|trim}
- </head>
- <!-- <neck></neck> -->{***************** Area 3 [processed second] *****************}
- <body class="{$body_class|trim}">
- {if $default_navbar_style!=="none"}
- {Navigator}
- {/if}
- <main{if $default_navbar_style=="fixed"} class="mt-5 pt-5"{/if}>
- {block name='content'}
- <div class="{$container_class}">
- <div class="{$row_class}">
- <div class="col-md-12">
- <h2>{$page_title}</h2>
- {$content1}
- </div>
- </div>
- </div>
- {/block}
- </main>
- {if $default_footer_style!=="none"}
- <footer{if $default_footer_style=="sticky"} class="sticky-footer"{/if}>
- <div class="container">
- <div class="row">
- <div class="col-12 text-center pt-1">
- © {sitename}
- <i class="fa fa-desktop primary pl-5" aria-hidden="true"></i>
- <span class="text-small-caps">
- <span class="d-inline d-sm-none">xs</span>
- <span class="d-none d-sm-inline d-md-none">sm</span>
- <span class="d-none d-md-inline d-lg-none">md</span>
- <span class="d-none d-lg-inline d-xl-none">lg</span>
- <span class="d-none d-xl-inline">xl</span>
- </span>
- </div>
- <div class="col-12 pt-1">
- {if $debug_mode}
- <hr /><ul>
- <li><b>$site_name:</b> {$site_name}</li>
- <li><b>$canonical_url:</b> {$canonical_url}</li>
- <li><b>$root_url:</b> {$root_url}</li>
- <li><b>$page_description:</b> {$page_description}</li>
- <li><b>$page_keywords:</b> {$page_keywords}</li>
- <li><b>$page_image:</b> {$page_image}</li>
- <li><b>$page_lang:</b> {$page_lang}</li>
- <li><b>$page_modified:</b> {$page_modified}</li>
- <li><b>$page_title:</b> {$page_title}</li>
- <li><b>$theme_url:</b> {$theme_url}</li>
- <li><b>$theme_color:</b> {$theme_color}</li>
- <li><b>$favicon_png:</b> {$favicon_png}</li>
- <li><b>$favicon_ico:</b> {$favicon_ico}</li>
- <li><b>$twitter_handle:</b> {$twitter_handle}</li>
- <li><b>$author_name:</b> {$author_name}</li>
- </ul><hr />
- {/if}
- </div>
- </div>
- </div>
- </footer>
- {/if}
- <!-- Include compiled minified JS -->
- {cgjs_render no_css=1}
- {if !empty($google_analytics_key)}
- <!-- Google Analytics -->
- <script async src="https://www.googletagmanager.com/gtag/js?id={$google_analytics_key}"></script>
- <script>
- window.dataLayer = window.dataLayer || [];
- function gtag(){
- dataLayer.push(arguments);
- }
- gtag('js', new Date());
- gtag('config', '{$google_analytics_key}');
- </script>
- {/if}
- {if !empty($footer_js)}
- {$footer_js}
- {/if}
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement