Android - redirect to store if app not installed (launch from website)

前端 未结 2 1533
鱼传尺愫
鱼传尺愫 2020-12-02 23:39

We have an android app that is launched when the user is redirected to a custom protocol. We want to have the user redirect to the google/play store for the app if it isn\'t

2条回答
  •  我在风中等你
    2020-12-03 00:21

    You could define a server-side URL that simply redirects to the application page in Google Play, and use that URL in an intent filter to be captured by your application:

    • If your application is installed, the activity for which you define the intent-filter will be opened.
    • If your application is not installed, the intent-filter will not be found and the browser will be opened and the user will be redirected to Google Play (being prompted if they want to open the Play Store or continue in the browser).

提交回复
热议问题