Normalise cookie data into a \WpOrg\Requests\Cookie
Parameters
$cookie
string|WpOrgRequestsCookierequired- Cookie header value, possibly pre-parsed (object).
$key
stringoptional- The name for this cookie.
Default:
''
Source
public function normalize_cookie($cookie, $key = '') {
if ($cookie instanceof Cookie) {
return $cookie;
}
return Cookie::parse($cookie, $key);
}
User Contributed Notes
You must log in before being able to contribute a note or feedback.