This popup still shows after using !is_front_page(). I am trying to check for cookie and the page

function test_popup_cookie() { setcookie(‘test-popup’, true, time() + (5), ‘/’); if (isset($_COOKIE[‘test-popup’]) && !is_front_page() ) { wp_enqueue_script(‘test-js’,get_template_directory_uri() . ‘/js/logcookie.js’,array(‘jquery’), ‘2.5’, true);…