I use following code to create a cookie, but faild.(iOS SDK 5)
// add cookie
NSDictionary *properties = [NSDictionary dictionaryWithObjectsAndKeys:
req.URL, NSHTTPCookieOriginURL,
@"MLSTORAGE", NSHTTPCookieName,
@"1234567890", NSHTTPCookieValue,
nil];
NSHTTPCookie *cookie = [NSHTTPCookie cookieWithProperties:properties];
NSLog(@"\nurl: %@\ncookie: %@", req.URL, cookie);
[[NSHTTPCookieStorage sharedHTTPCookieStorage] setCookie:cookie];
//
the log is:
2012-07-26 18:30:49.914 Motilink[15289:707] -[FMWebDAVRequest sendRequest:][Line 154]
url: http://210.116.114.195:8080/MLServer/storage/
cookie: (null)
any one know how to create a cookie?