Open facebook page in App not the browser [duplicate]

烈酒焚心 提交于 2019-12-25 18:15:33

问题


I have a link to my facebook, on my website, which opens in the phone's browser.

I would like it to open in the facebook app by default, if the app is installed.

Is this possible?


回答1:


In general it may not be possible, check this thread: https://android.stackexchange.com/questions/37549/force-link-to-open-in-app-not-my-default-browser

But if you really want to do it, you can follow the same principle as it is proposed on this URL: Open Facebook page from Android app?

In short, try to build an URL of form: fb://profile/pageID. The point of building such URL is because of IntentFilter defined in Facebook app. I am not sure if it will work, but if there is no Facebook app installed this will probably fail.

That should work when you click on a link in browser. It may depend on a browser though.



来源:https://stackoverflow.com/questions/37320903/open-facebook-page-in-app-not-the-browser

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!