Reputation: 1664
Upon tap of a button, I am trying to send the user to a Facebook page.
I am testing with a random page like this, which exists: http://facebook.com/WorldwideCollection
Here is how I attempt to launch the page in Facebook app:
NSURL *url = [NSURL URLWithString:@"fb://page/WorldwideCollection"];
if ([a canOpenURL:url]) {
[a openURL:url];
return;
}
Facebook app is logged in and opens. But all I see is my own timeline. It does not direct the user to the page as requested. Is there a different way of doing it?
Upvotes: 0
Views: 77
Reputation: 893
Check this link, this was answered on stackoverflow
Especially check these lines of code.
NSURL *urlApp = [NSURL URLWithString:@"fb://profile/****123****"];
[[UIApplication sharedApplication] openURL:urlApp];
Upvotes: 0
Reputation: 5616
You need to use profile with the Facebook id for the page :
fb://profile/(fbid)
Upvotes: 1
Reputation: 2369
You need to use facebookID of your page to visit like this
//Stackoverflow Page
fb://page/11239244970
Upvotes: 0