#9 adding cookie method