Open Flickr From Third Party iOS App

2019-08-31 02:18发布

I want to forward my users to the Flickr app -if they have it of course- and if they don't to Flickr mobile. I want to make sure that they will see my page. I can do this with Facebook and Twitter by a link like twitter://... However, I don't know the link style of Flickr. Can someone help me. Thanks you!

3条回答
Evening l夕情丶
2楼-- · 2019-08-31 02:54

What you're thinking of is called a URL-Scheme. I trying to look up the info, but I think that the developers at Flickr didn't think this through. An example post of my search is right here.

It seems that Flickr only has the flickr:// scheme, which opens the app, but not more than that. It's a shame.

查看更多
地球回转人心会变
3楼-- · 2019-08-31 03:01

The new version has flickr://photos/username/photoID. You can either use the username or nsid. Both work.

查看更多
仙女界的扛把子
4楼-- · 2019-08-31 03:03

Currently, the way to solve this is to open the web URL. The website will redirect you to the app if it's installed.

More on this here: https://www.flickr.com/services/api/misc.urls.html

Example in Objective-C:

                                                           //Photo owner id/photo id
NSString *flickrUrlString = @"https://www.flickr.com/photos/12037949754@N01/155761353";
NSURL *flickrUrl = [[NSURL alloc] initWithString: flickrUrlString];
if ([[UIApplication sharedApplication] canOpenURL:flickrUrl]) {
    [[UIApplication sharedApplication] openURL:flickrUrl];
} else {
    NSLog(@"Unable to open url: %@", flickrUrl);
}
查看更多
登录 后发表回答