javascript - How can I make a popup show up only if the device is android? -


i trying make popup appear if person traveled on website using android device. have seen done on other websites can't seem figure out how this. attaching screenshot of wanting do.

enter image description here

please if can please me appreciate it.

you can check user agent , if android device, call code display pop this:

var ua = navigator.useragent.tolowercase(); var isandroid = ua.indexof("android") > -1;  if(isandroid) {     // call popup code here } 

Comments

Popular posts from this blog

google chrome - Developer tools - How to inspect the elements which are added momentarily (by JQuery)? -

angularjs - Showing an empty as first option in select tag -

php - Cloud9 cloud IDE and CakePHP -