Вопрос

my problem that the below code:

 [[NSHTTPCookieStorage sharedHTTPCookieStorage] deleteCookie:cookie];

works fine with ios 5 but with ios6 cookies are not deleted and the web view still uses the same cookies setted before.

Does anyone has an idea about this issue?

Update

after killing the app , it works fine.

Это было полезно?

Решение

The problem was with this method which i used to make authentication:

- (void)connection:(NSURLConnection *)connection didReceiveAuthenticationChallenge:(NSURLAuthenticationChallenge *)challenge{


       [[challenge sender] useCredential:[NSURLCredential credentialWithUser:Username password:Password persistence:CredentialsPresistance]


forAuthenticationChallenge:challenge];
}

the "persistence" ought to be equal to NSURLCredentialPersistenceNone in ios6 only.

This solved my problem.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top