<script type="text/javascript">
<? if (get_cookie("ck_mobile") == "") { ?>
var mobilewords = new Array("Windows CE","Mobile");
for (var word in mobilewords) {
if (navigator.userAgent.match(mobilewords[word]) != null && confirm("모바일 브라우저 입니다. 모바일 페이지로 이동하시겠습니까?")) {
set_cookie("<?=md5('ck_mobile')?>","<?=base64_encode('buspang-mobile')?>", 1, "<?=$g4['cookie_domain']?>");
///m 모바일 페이지로 이동
location.href = "http://" + location.host + "/m" + location.pathname;
break;
} else {
set_cookie("<?=md5('ck_mobile')?>","<?=base64_encode('buspang-pc')?>", 1, "<?=$g4['cookie_domain']?>");
}
}
<? } else if (get_cookie("ck_mobile") == "buspang-mobile") { ?>
location.href = "http://" + location.host + "/m" + location.pathname;
<? } ?>
</script>
<!-- 모바일 브라우저 인식 -->
- opencode.co.kr -