From 0f71f879bf82227838beb84d6b072c53e94db9fd Mon Sep 17 00:00:00 2001 From: somratpro Date: Sun, 18 Oct 2020 13:19:01 +0600 Subject: added js-cookies --- exampleSite/config.toml | 7 ++++++- layouts/partials/footer.html | 43 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 49 insertions(+), 1 deletion(-) diff --git a/exampleSite/config.toml b/exampleSite/config.toml index 16bf2bd..2da134f 100644 --- a/exampleSite/config.toml +++ b/exampleSite/config.toml @@ -106,7 +106,6 @@ weight = 2 languageCode = "en-us" title = "Example site multi-language" dateFormat = "January 2, 2006" - home = "EN Home" logo = "images/logo.png" menufixed = false @@ -117,6 +116,12 @@ footerQuicklinkTitle = "Quicklinks" footerAboutTitle = "About" footerSubscribeTitle = "Subscribe" + +# cookies +[params.cookies] +enable = true +expire_days = 2 + # Hero Area Section [Languages.en.params.hero] enable = true diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index 9be2cae..dc9661c 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -71,3 +71,46 @@ {{ "" | safeHTML }} {{ $script := resources.Get "js/script.js" | minify}} + + +{{ if site.Params.cookies.enable }} + + + + + + +{{ end }} \ No newline at end of file -- cgit v1.2.3