diff --git a/assets18/js/common.js b/assets18/js/common.js deleted file mode 100644 index 3435b12..0000000 --- a/assets18/js/common.js +++ /dev/null @@ -1,23 +0,0 @@ -/*! - * Author: Pierre-Henry Soria - * Copyright: (c) 2020, Pierre-Henry Soria. All Rights Reserved. - */ - -const disagreedRedirectLink = "https://google.com"; // <= URL to show when the visitor is likely to be under 18yrs - -Disclaimer.generateDialog(); - -const oDisclaimer = new Disclaimer(); -if (!oDisclaimer.isAccepted()) { - oDisclaimer.loadDialog(); - oDisclaimer.centerDialog(); -} - -document.getElementById('agree-over18').onclick = function () { - oDisclaimer.disableDialog(); - oDisclaimer.setAccepted(); -}; - -document.getElementById('disagree-under18').onclick = function () { - location.href = disagreedRedirectLink -}