I would like to set a "destination" cookie for all users on my site, to serve tailored content. The cookie needs to persist across login/logout so it appears I cannot use jSession, which is cleared on login/logout.
I can sort of achieve this the old fashioned way
setcookie( "destinationcookie", $_POST['destination'], strtotime( '+90 days' ) );
$destination = isset($_POST['destination']) ? $_POST['destination'] : $_COOKIE["destinationcookie"];
...but I'm sure joomla has a better way hidden away somewhere. PS - the documentation on this is practically non-existent as far as I can find.