Handling cookies
Content Experiments rely on cookies to store session data about the Content Variant a visitor is viewing and make sure they always see the same one. By default, SmartTarget will try to write httpOnly cookies, unless you are using REL in which case SmartTarget cannot directly read and write cookies, or if it cannot write the cookies in the header, for example when the response buffer is flushed. A JavaScript cookie is written when an httpOnly cookie cannot be used.
About this task
- Changing the buffer size
-
When the response buffer is flushed (that is, it is kept low for performance reasons), the header is sent in the response before SmartTarget can write the
httpOnlycookie. In this case, the tags or controls will output JavaScript to set a cookie to avoid invalidating the Experiment. - Writing out cookies for REL–based implementation
-
If your Output Format is
REL(Render Engine Language), the Content Delivery Web service renders content at request time. SinceRELhas no Web context, SmartTarget cannot directly read and write cookies.