PHP code example of cuephp / cookie
1. Go to this page and download the library: Download cuephp/cookie library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
cuephp / cookie example snippets
use CuePhp\CookieManager;
$cookie = CookieManager::createFromHeaders($cookieString); // cookie string is from http header
// get cookie value
$cookie->getValue();
use CuePhp\CookieManager;
$cookie = CookieManager::new( 'name', 'value' );
CookieManager::setToClientHeaders($cookie); // will set response header set-cookie
use CuePhp\CookieManager;
$cookie = CookieManager::new( 'name', 'value', {$options} );