티스토리 뷰

<%@ page language="java" contentType="text/html; charset=UTF-8"

    pageEncoding="UTF-8"%>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<html>

<head>

<meta charset="utf-8">

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">

<script type="text/javascript">


var isIPHONE = (navigator.userAgent.match('iPhone') != null || navigator.userAgent.match('iPod') != null);

var isIPAD = (navigator.userAgent.match('iPad') != null);

var isANDROID = (navigator.userAgent.match('Android') != null);


 

function executeApp(url) {

if (isANDROID) {

location.href = "tstore://PRODUCT_VIEW/0000386538/0";

}

        installApp();

        if (isIPHONE || isIPAD) {

//                 window.location.href = url;

        } else if (isANDROID) {

                $('applinkDiv').innerHTML = '<iframe src="' + url + '" width="0" height="0" frameborder="0"></iframe>';

                setTimeout(function(){

                        var b = $('applinkDiv');

                        var c = b.getElementsByTagName('iframe');

                        if (c.length > 0) { b.removeChild(c[0]); }

                }, 1000);

        }

}

 

function installApp() {

        var b = new Date();

        setTimeout(function(){

                if (new Date() - b < 500) {

                        if (isANDROID) {

                            location.href = "market://details?id=com.inucompany.honeybridge9";

                        }

                }

        }, 500);

        if (isIPHONE || isIPAD) {

                                location.href = "http://itunes.apple.com/app/id661986436?mt=8";

                        } 

}


</script>

</head>

<body>


<script type="text/javascript"> 

window.onload=function() { executeApp("tstore://PRODUCT_VIEW/0000386538/0"); } 

</script> 


<div id="applinkDiv"></div>

</body>

</html>


참고 : http://blog.taks.pe.kr/34

댓글
댓글쓰기 폼
공지사항
Total
826,119
Today
77
Yesterday
354
«   2020/07   »
      1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31  
글 보관함