K
K
KriopeG2012-06-05 09:50:28
Android
KriopeG, 2012-06-05 09:50:28

Is it possible to determine the presence of an application on a smartphone when visiting a site?

Good day!
Tell me, is it possible to somehow check if the required application is installed on the site when accessing a specific site from a mobile device (android, ios) (For example, in order to show a link to the application in the market on the site if it is not available on the smartphone).
If it is possible, please tell me how? Where can you read.

Answer the question

In order to leave comments, you need to log in

8 answer(s)
F
feel_good, 2012-06-05
@feel_good

You can, but it's more like a hack.
Register a Custom URL Scheme in the application, check on the site whether this URL can be opened, if not, the application is not installed

A
Alexey Chernyshev, 2015-12-29
@nanomen

There is a standard banner from Apple - Smart App Banners
It is enough to put a meta tag on the page:
< meta name ="apple-itunes-app" content ="app-id=myAppStoreID, affiliate-data =myAffiliateData, app-argument =myURL">
app -id - 9 digits of the application ID (can be taken from the url - https://itunes.apple.com/ru/app/danceconvention.ne...
More details about affiliate-data and app-argument can be found in the documentation
https:// developer.apple.com/library/ios/documentat...

Y
yeleleo, 2012-07-06
@yeleleo

It is possible, but it is done on the server and uses Custom URL Scheme for this.
For example, in python it looks like this:

class ConnectHandler(webapp.RequestHandler):

    def get(self, link_id):
        try:
            link = LinkModel.gql("WHERE link=:1", link_id).get()
            if link is None:
                raise LinkNotFoundError
        except (db.BadKeyError, LinkNotFoundError):
            self.error(400)
            return
        user_agent = self.request.headers['User-Agent'].lower()
        if user_agent.find('ipad') != -1:
            self.redirect('/ipad/' + link_id)
        elif user_agent.find('iphone') == -1 and user_agent.find('ipod') == -1:
            self.redirect('/noiphone')
        else:
            self.redirect('/iphone/' + link_id)

app = webapp.WSGIApplication(service_mappings + [
    (r'/noiphone', NoIphoneHandler),
    (r'/iphone/([a-zA-Z0-9-_]{1,256})', IphoneHandler),
    (r'/iphoneno', IphoneNoAppHandler),
    ] )

A
Alexey Sidorov, 2012-06-05
@Gortauer87

No, only through hacks.

A
Antelle, 2012-06-05
@Antelle

Probably not. If so, it's a security hole.

N
Nikolai Turnaviotov, 2012-06-05
@foxmuldercp

can try to poke into the Google market or the apple market with authorization from the client and ask the market if the “softina” is installed on such and such a device. directly into the OS you are unlikely to be allowed

E
EndUser, 2012-06-05
@EndUser

A bunch of forums offer android software for visiting it.
Tapatalk is especially annoying.
Obviously, the software, unlike the browser, either gives a reference or a specific URL, but this is no longer important. tapatalk will surely find a way to prove itself in front of the site.
And if you have the same tapatalk on the side and enter through a normal browser, I'm sure the site will again offer installation.

A
Alexander, 2012-06-05
@Alexx_ps

If the hacks mentioned above can really be implemented, then your site will most likely come under the attention of antivirus companies in the near future. They put sites on their blacklist for even lesser things.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question