script popup for android and iOS - for your device exist app, how? -


i developed simple android , ios app. want when user in site (from mobile phone), popup text redirect google play or apple store, "for device available android or ios application".

my question how that? script can put in website when user surfing on website mobile device popup information exist mobile application device?

thank you

the way this, first find mobile type using mobile agent , base on redirect correct locations. e.g. putting java scripts on top of header page between

<head></head>  <script> if( /iphone|ipod/i.test(navigator.useragent) ) { window.location = "your apple app url goes here"; } else if( /android/i.test(navigator.useragent) ) { window.location = "your google play app url goes here"; } </script> 

Comments

Popular posts from this blog

php - Submit Form Data without Reloading page -

linux - Rails running on virtual machine in Windows -

php - $params->set Array between square bracket -