我对iphone开发有点陌生..所以请多多包涵!
我有一个连接到我开发的 REST API 的登录屏幕。它来回发送 json 请求。基本上,当您单击登录时,它会检查用户名/密码是否有效(显然)。
这是我所拥有的基本逻辑:
- (IBAction)sendLoginJson:(id)sender {
// send JSON request to server.. etc
NSURLConnection *myConnection = [NSURLConnection connectionWithRequest:request delegate:self];
[myConnection start];
}
然后前往
- (void)connectionDidFinishLoading
// this is where I get the response from the server
在确保登录已正确验证后,如何切换到“DashboardViewController”?
谢谢!