I set cookie on my landing pages with loading this JS code into an iframe (iframe.com/cookie.html):
function setCookie(cname, cvalue, exdays, exhours, exmins,