This question relates to: Is it possible to add http headers. for example set-cookie, via ampscript or ssjs in ExactTarget?
The answer on that question does not specifically call out how to set a cookie with SSJS, it just references the HTTPHeader.SetValue() function.
I've tried the following to set the cookie and have been unsuccessful.
HTTPHeader.SetValue("Set-Cookie","foo=bar");
HTTPHeader.SetValue("Cookie","foo=bar");
Any thoughts as to what I'm doing wrong?
Set-Cookie: theme=light
I'm still missing how I'm doing it wrong in the context of SSJS. Can you enlighten me and provide example code that should work?