What is wrong with this javascript code I made?

<html>

<head>

<script>

function checkcookie(){

if(document.cookie.indexof(“Age”) >= ){

}else if(document.cookie.indexof(“Age”) < ){

}else if(document.cookie.indexof(“Age”) == “Un-decided”){

}else{

document.cookie = ‘Age=Un-Decided; expires Fri, th Mar :: UTC; path=/’

alert(“Age Veryfier”);

}

}

checkcookie();

</script>

</head>

<body>

</body>

</html>

✅ Answers

  • See…

    Source(s): http://www.wschools.com/js/js_cookies.asp

  • try working with $_COOKIE, just search for it in google

  • Leave a Comment