The first thing when loading a page is to look for the cookies. You could use:
<body onload="checkCookie()">
reading a cookie is not a straight foreword thing. read this
http://www.w3schools.com/js/js_cookies.asp
P.S. I used Firefox to check for the cookies and yours are set.