Answers
所有的cookie都会在这里面
NSHTTPCookieStorage *sharedHTTPCookieStorage = [NSHTTPCookieStorage sharedHTTPCookieStorage]; NSArray *cookies = [sharedHTTPCookieStorage cookiesForURL:[NSURL URLWithString:theURL]]; NSEnumerator *enumerator = [cookies objectEnumerator]; NSHTTPCookie *cookie; while (cookie = [enumerator nextObject]) { NSLog(@"COOKIE{name: %@, value: %@}", [cookie name], [cookie value]); }
Ppeng
answered 10 years, 6 months ago