cleaned up a bit, added cookie access.