1

I want to open a page in fb app using a deep link (on.fb.me/xxx) but it opens in the web browser, is there a way I can do this? or Am I forced to use the usual fb url (fb://xxx).

the code I'm using right now

final Uri uri = Uri.parse("http://on.fb.me/xxx");

    final Intent facebookIntent = new Intent(Intent.ACTION_VIEW, uri);
    facebookIntent.setPackage("com.facebook.katana");
    try {
        startActivity(facebookIntent);
    } catch (ActivityNotFoundException e) {
        startActivity(new Intent(Intent.ACTION_VIEW, uri));
    }

I have the same issue with Instagram and Twitter with links like "bit.ly/xxx"

Boukharist
  • 1,219
  • 11
  • 19
  • have you checked this? http://stackoverflow.com/questions/4810803/open-facebook-page-from-android-app – user1506104 Feb 06 '17 at 15:49
  • yep, but this only works with normal links or page name, but I want to use a smartlink in order to track redirictions. – Boukharist Feb 06 '17 at 15:52

0 Answers0