add cookie code