I need to add sign in and sign up option so i am little confuse that whether I'll use Sqlite to store user's credential or using web service(PHP)?
if anyone knows开发者_StackOverflow better option except above both operation then please guide me.
you are storing a username and password you could use the Keychain.
To use Keychain import "Security/Security.h".
Apple has an example of adding and retrieving a username and password in their documentation. The example methods
- (void)mySetObject:(id)inObject forKey:(id)key;
- (id)myObjectForKey:(id)key;
- (void)resetKeychainItem;
will enable you to persist and retrieve your user credentials almost without modifying the example code.
Calling webservices that require authentication, provide username and password directly as parameters in the URL using NSURLConnection
精彩评论