__toString() public method
Magic method to turn a cookie object into a string without having to explicitly access $value.
if (isset($request->cookies['name'])) { $value = (string) $request->cookies['name']; }
public string __toString ( ) | ||
---|---|---|
return | string |
The value of the cookie. If the value property is null, an empty string will be returned. |
Please login to continue.