Search This Blog

Monday, December 18, 2017

android detection dengan javascript

<script>
var ua = navigator.userAgent.toLowerCase();
var isAndroid = ua.indexOf("android") > -1; //&& ua.indexOf("mobile");
if(isAndroid) {
//vnd.youtube://youtube.com/user/suryaprocell
 window.location = 'http://youtube.com/user/suryaprocell';
}
</script>

No comments:

Post a Comment