Web/scripts/cookies.js

15 lines
653 B
JavaScript
Raw Normal View History

if (cookieNotification) {
let notif = "";
notif += '<div class="alert alert-danger alert-dismissible fade show" role="alert">';
2020-04-02 21:54:20 +02:00
notif += "This site uses cookies to store information about your browsing activity.";
notif += "<br>For more information, check out the <a href=\"#privacy\">privacy policy</a>.";
notif += "<br>Have a nice day!";
notif += '<button type="button" class="close" data-dismiss="alert" id="notif-close">';
notif += '<span>&times;</span>';
notif += '</button></div>';
document.write(notif);
$("#notif-close").on("click", function () {
setCookie("notification", "true", 365);
});
}