A Zend_Http_Cookiejar object is designed to contain and maintain HTTP cookies, and should be used along with Zend_Http_Client in order to manage cookies across HTTP requests and responses.
The class contains an array of Zend_Http_Cookie objects. Cookies can be added and removed from this array in various ways. The jar can also be useful in returning only the cookies needed for a specific HTTP request.
A special parameter can be passed to all methods of this class that return cookies: Cookies can be returned either in their native form (as Zend_Http_Cookie objects) or as strings - the later is suitable for sending as the value of the "Cookie" header in an HTTP request. You can also choose, when returning more than one cookie, whether to get an array of strings (by passing Zend_Http_Cookiejar::COOKIE_STRING_ARRAY) or one unified string for all cookies (by passing Zend_Http_Cookiejar::COOKIE_STRING_CONCAT).
See http://wp.netscape.com/newsref/std/cookie_spec.html for some specs.
Located in /Zend/Http/Cookiejar.php (line 44)
Create a new CookieJar object and automatically load into it all the cookies set in an Http_Response object. If $uri is set, it will be considered as the requested URI for setting default domain and path of the cookie.
Construct a new CookieJar object
Add a cookie to the jar. Cookie should be passed either as a Zend_Http_Cookie object or as a string - in which case an object is created from the string.
Parse an HTTP response, adding all the cookies set in that response to the cookie jar.
Remove all cookies from the jar
Delete a cookie according to it's name and domain. If no name is specified, all cookies from this domain will be cleared out.
Clear all cookies who's expiry time is older than $time
Clear "Session" cookies (cookies without specific expiry time)
Get all cookies in the cookie jar as an array
Get a specific cookie according to a URI and name
Return an array of all cookies matching a specific request according to the request URI, whether session cookies should be sent or not, and the time to consider as "now" when checking cookie expiry time.
Helper function to recursivly flatten an array. Shoud be used when exporting the cookies array (or parts of it)
Return a subset of the cookies array matching a specific domain
Returned array is actually an array of pointers to items in the $this->cookies array.
Return a subset of a domain-matching cookies that also match a specified path
Returned array is actually an array of pointers to items in the $passed array.
Documentation generated on Sun, 29 Oct 2006 21:27:53 -0600 by phpDocumentor 1.3.0RC6