1
我有一個應用程序,我有一個按鈕。我想在瀏覽器中打開一個fb登錄網址,當我登錄成功後,我想回到我的應用程序。所以問題是我如何解決這個問題?如何在點擊按鈕後添加新窗口並返回到上一個窗口?
我使用此代碼。
-(IBAction)add_account:(id)sender{
switch (((UIButton*)sender).tag){
case 0:
{
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"http://graph.facebook.com/oauth/authorize?client_id=xxxxxxxxxxxxx&redirect_uri=http://www.facebook.com/connect/login_success.html&type=user_agent&display=touch&scope=offline_access,publish_stream,read_stream"]];
break;
}
}
}
感謝在進步......