Storing Data
// Set cookie data
Cookie::set($key, $value);
// Store a user id
Cookie::set('user_id', 10);
Retrieving Data
// Get cookie data
$data = Cookie::get($key, $default_value);
// Get the user id
$user = Cookie::get('user_id');
Deleting Data
// Delete cookie data
Cookie::delete($key);
// Delete the user id
Cookie::delete('user_id');
En el archivo bootstrap.php
// Set cookies to expire after 1 week Cookie::$expiration = 604800; // Alternative to using raw integers, for better clarity Cookie::$expiration = Date::WEEK;