在iOS应用程序中打开Google Plus页面的链接?
我想从iOS 7应用程序打开我的g+页面。与下面我们为Facebook和Twitter所做的类似在iOS应用程序中打开Google Plus页面的链接?,ios,iphone,objective-c,ios7,google-plus,Ios,Iphone,Objective C,Ios7,Google Plus,我想从iOS 7应用程序打开我的g+页面。与下面我们为Facebook和Twitter所做的类似 - (IBAction)likeMeOnFacebook:(id)sender { NSURL *urlApp = [NSURL URLWithString:@"fb://profile/{Enter ID Here}"]; [[UIApplication sharedApplication] openURL:urlApp]; } - (IBAction)followMeOnTwi
- (IBAction)likeMeOnFacebook:(id)sender {
NSURL *urlApp = [NSURL URLWithString:@"fb://profile/{Enter ID Here}"];
[[UIApplication sharedApplication] openURL:urlApp];
}
- (IBAction)followMeOnTwitter:(id)sender {
NSURL *urlApp = [NSURL URLWithString:@"twitter://user?screen_name={Enter ID Here}"];
[[UIApplication sharedApplication] openURL:urlApp];
}
- (IBAction)followMeOnTwitter:(id)sender {
// Need code to open Google Plus page
// Help me out to find out the URL
NSURL *urlApp = [NSURL URLWithString:@""];
[[UIApplication sharedApplication] openURL:urlApp];
}
可能重复的
// Google +
NSURL *googlePlusURL = [[NSURL alloc] initWithString:@"gplus://plus.google.com/+Mypizza"];
// check if app is installed
if ( ! [[UIApplication sharedApplication] canOpenURL:googlePlusURL] ) {
// if we get here, we can't open the Google app.
googlePlusURL = [[NSURL alloc] initWithString:@"https://plus.google.com/+Mypizza"];
}
[[UIApplication sharedApplication] openURL:googlePlusURL];