You already have the code - how many times do I have to tell you - take one line and move it up. Then run your code and check your local cookies directory for the stored cookie.
dayve, I dont think you have made a point yet. So far you have insisted all the documentation is wrong and have requested that I send your own code back so you can tell me it works.
Having read the documentation and found that what it says is true, I've long since moved on with my code.
I'm not looking for documentation. Obviously you asked the question so you can put it to use on something you're working on. I'd like to see how you were using it to find out why you seem to be the ONLY person having problems with cookies.... but then I realized I am wasting my time so told you to forget it.