From 30d9e7e593ec5d64d1b454fccd0698cf6b64a33e Mon Sep 17 00:00:00 2001 From: somratpro Date: Thu, 8 Oct 2020 10:52:15 +0600 Subject: added cookie popup --- exampleSite/config.toml | 5 +++++ layouts/partials/footer.html | 46 +++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 50 insertions(+), 1 deletion(-) diff --git a/exampleSite/config.toml b/exampleSite/config.toml index db3ae26..bc65b77 100644 --- a/exampleSite/config.toml +++ b/exampleSite/config.toml @@ -86,6 +86,11 @@ map_latitude = "51.5223477" map_longitude = "-0.1622023" map_marker = "images/marker.png" +# cookies +[params.cookies] +enable = true +expire_days = 2 + # social site [[params.social]] icon = "ti-facebook" diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index 2c2ec7e..7d01134 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -70,4 +70,48 @@ {{ "" | safeHTML }} {{ $script := resources.Get "js/script.js" | minify}} - \ No newline at end of file + + + + +{{ if site.Params.cookies.enable }} + + + + + + +{{ end }} \ No newline at end of file -- cgit v1.2.3