I have an app that has a table view with a list of Facebook pages. When the user selects a row it should open the page in the Facebook app and if the user doesn't have the app installed it will open the page in Safari. It will open in Safari fine but when it opens in the FB app it says "The page you requested was not found". I'm doing the same thing with some Twitter pages and all of those work just fine.
Here is my FB code:
Any ideas?
Here is my FB code:
Code:
NSURL *facebookURL2 = [NSURL URLWithString:@"fb://profile/403322143067515"];
NSURL *safariURL2 = [NSURL URLWithString:@"https://facebook.com/KYRoadsideFarmMarkets"];
if (indexPath.row == 1)
{
if ([[UIApplication sharedApplication] canOpenURL:facebookURL2])
{
[[UIApplication sharedApplication] openURL:facebookURL2];
}
else
{
[[UIApplication sharedApplication] openURL:safariURL2];
}
}
Any ideas?