<?php
/* * * * * * * * * * * * * * * * * * * *
 *  ██████╗ █████╗  ██████╗ ███████╗
 * ██╔════╝██╔══██╗██╔═══██╗██╔════╝
 * ██║     ███████║██║   ██║███████╗
 * ██║     ██╔══██║██║   ██║╚════██║
 * ╚██████╗██║  ██║╚██████╔╝███████║
 *  ╚═════╝╚═╝  ╚═╝ ╚═════╝ ╚══════╝
 *
 * @author   : Daan van den Bergh
 * @url      : https://daan.dev/wordpress/caos/
 * @copyright: © 2021 - 2023 Daan van den Bergh
 * @license  : GPL2v2 or later
 * * * * * * * * * * * * * * * * * * * */
?>
<script>
    function getCookieValue(name) {
        cookies = document.cookie;
        cookiesArray = cookies.split('; ');
        cookieValue = null;
        cookiesArray.forEach(function(cookie) {
            cookieArray = cookie.split('=');
            if (cookieArray[0] !== name) {
                return;
            }
            cookieValue = cookieArray[1];
        });
        return cookieValue;
    }

    cookieValue = getCookieValue('<?= CAOS::get(CAOS_Admin_Settings::CAOS_BASIC_SETTING_COOKIE_NOTICE_NAME); ?>');
</script>