分类: Python/Ruby
2010-09-26 15:47:21
The cookielib module defines classes for automatic
handling of HTTP cookies. It is useful for accessing web sites that require
small pieces of data - cookies - to be set on the client
machine by an HTTP response from a web server, and then returned to the server
in later HTTP requests.
The following classes are provided:
policy=None) |
The CookieJar class stores HTTP cookies. It extracts cookies from HTTP requests, and returns them in HTTP responses. CookieJar instances automatically expire contained cookies when necessary. Subclasses are also responsible for storing and retrieving cookies from a file or database.
filename, delayload=None, policy=None) |
A CookieJar which can load cookies from, and perhaps save cookies to, a file on disk. Cookies are NOT loaded from the named file until either the load() or revert() method is called. Subclasses of this class are documented in section 18.22.2.
chinaunix网友2010-09-27 10:48:51
很好的, 收藏了 推荐一个博客,提供很多免费软件编程电子书下载: http://free-ebooks.appspot.com