I have a cookie set with javascript, I created it like this:
document.cookie='gravado=sim'
I do not know how to check if it exists. I need to do a check because if it does not exist, I'll redirect to another page, I also need to know how I can destroy this cookie.