1

On my android phone I launch an standard browser, after enter my URL www.example.com and press open. I need some ways to determine if I have installed on my phone for example MYAPP, must I write an plugin for my Android browser or may be I must add some java functionality to my web site or maybe something else ?

I need some information, articles or something else of how can I do that, every kind of information will be helpful.

Aleks G
  • 52,841
  • 25
  • 149
  • 233
Viktor Apoyan
  • 10,241
  • 20
  • 81
  • 141
  • The simple answer is _this cannot be done_. Think about it: you visit some random website - and that site can read information about what apps you have installed on your phone. Would you want that? If you need some info about a particular app (_your app_), then you need to code that app to connect to the website and send relevant info. – Aleks G Sep 11 '12 at 18:34
  • Agreed, what you are asking for would be a major privacy breach. – CommonsWare Sep 11 '12 at 18:59
  • @AleksG and if I write a plugin for Android browser can I in that case determine if application is installed on a Phone ? – Viktor Apoyan Sep 14 '12 at 12:45
  • @CommonsWare do you know if I can write a plugin for web Android web browser ? Or it is impossible ? – Viktor Apoyan Sep 14 '12 at 12:46
  • @ViToBrothers Where are you trying to determine this from? If you want you website to determine whether an app is installed, then you cannot do it on its own. You can write an app, which would monitor where the user is going with the browser and on your specific page perform some actions, but I don't think default android browser supports plugins. – Aleks G Sep 14 '12 at 13:13
  • @AleksG lets imagine situation. User come to my own web page from hist Android, my web page must try to determine if my own application is installed on the phone ? – Viktor Apoyan Sep 14 '12 at 13:23
  • @AleksG if you know for 100% that this is impossible, please provide some information were I can read about that, Thanks !!! – Viktor Apoyan Sep 14 '12 at 13:24
  • 1
    @ViToBrothers But the phone/browser does not now that it's _your_ webpage. The fact is, it is not possible. I can't provide you with a specific source: just search the internet - you'll find thousands of pages explaining that it is not possible to do. – Aleks G Sep 14 '12 at 13:45
  • 1
    @ViToBrothers: I do not know which browsers for Android support plugins or much about that process, sorry. The typical workaround for this problem is to have your app respond to a particular URL that you control (via an appropriate `` element in your `` of an ``), and link to that URL from, say, your home page. When the user clicks the link, if the app is installed, they will have the option to run your app. If the app is not installed, their browser will load the URL, which you set up to return information about how to download the app. – CommonsWare Sep 14 '12 at 16:56

2 Answers2

4

@Aleks G is correct, you cannot do this. However, you can make your app so that it will open when your web page is opened, given that it is already installed.

See here: Launch custom android application from android browser

Community
  • 1
  • 1
brthornbury
  • 2,958
  • 1
  • 18
  • 19
1

- I don't think that what you want to do is possible...

- Yet you can use BroadCast-Receiver to determine when you browser opened and then you can launch your app if its installed..

- Another way to manually check, that whether you app has been installed or not, please check the Manage Application from Application, under Setting.

Kumar Vivek Mitra
  • 32,278
  • 6
  • 43
  • 74