Syntax:
Cookies are accessed using the $_COOKIE superglobal array.
Example:
if(isset($_COOKIE["user"])) {
echo "Welcome " . $_COOKIE["user"];
} else {
echo "Welcome Guest!";
}
Syntax:
Cookies are accessed using the $_COOKIE superglobal array.
Example:
if(isset($_COOKIE["user"])) {
echo "Welcome " . $_COOKIE["user"];
} else {
echo "Welcome Guest!";
}