USER_AGENT 분석 함수 있으신 분?
혹시 그누보드의 get_brow()나 get_os()와 같은 함수를 공개해놓은 것을 보셨나요?
스마트폰을 종류별로 구분해놓은 것을 예전에 팁게시판에서 본 것 같기도 한데..
댓글 6개
15년 전
http://www.sir.co.kr/bbs/board.php?bo_table=g4_tiptech&wr_id=23688&sca=&sfl=wr_subject&stx=os&sop=and
15년 전
http://www.sir.co.kr/bbs/board.php?bo_table=g4_tiptech&wr_id=19295&sca=&sfl=wr_subject%7C%7Cwr_content&stx=get_brow&sop=and
terrorboys
15년 전
<script type="text/javascript">
document.write(navigator.userAgent) // os 출력
</script>
이렇게 해도 됩니다.
응용하면
<script type="text/javascript">
//script by kunmin, 2010-04-06
// 20100820 테러보이 수정
var mobilewords = new Array("Windows CE","Mobile","iPhone","Android","iPad","iPod","PSP");
for (var word in mobilewords) {
if (navigator.userAgent.match(mobilewords[word]) != null) {
document.write("당신은")
document.write(navigator.userAgent.match(mobilewords[word]))
document.write("로 접속하셨습니다.<br>")
break;
}
}
</script>
이렇게 쓸수 있지요.
document.write(navigator.userAgent) // os 출력
</script>
이렇게 해도 됩니다.
응용하면
<script type="text/javascript">
//script by kunmin, 2010-04-06
// 20100820 테러보이 수정
var mobilewords = new Array("Windows CE","Mobile","iPhone","Android","iPad","iPod","PSP");
for (var word in mobilewords) {
if (navigator.userAgent.match(mobilewords[word]) != null) {
document.write("당신은")
document.write(navigator.userAgent.match(mobilewords[word]))
document.write("로 접속하셨습니다.<br>")
break;
}
}
</script>
이렇게 쓸수 있지요.
15년 전
다음 주부터 프로젝트 진행입니다.
http://net.tutsplus.com/ 여기에 있는 비디오 강좌가 참 좋네요.
몇번 따라하면 도움이 많이 됩니다.^^
http://net.tutsplus.com/ 여기에 있는 비디오 강좌가 참 좋네요.
몇번 따라하면 도움이 많이 됩니다.^^
게시판 목록
자유게시판
| 번호 | 제목 | 글쓴이 | 날짜 | 조회 |
|---|---|---|---|---|
| 공지 |
|
1주 전 | 10 | |
| 199718 |
|
1주 전 | 9 | |
| 199717 | 3주 전 | 20 | ||
| 199716 |
느긋한카키쿠키
|
3주 전 | 17 | |
| 199715 |
현대적인무질서한까마귀
|
3주 전 | 20 | |
| 199714 | 3주 전 | 23 | ||
| 199713 | 3주 전 | 33 | ||
| 199712 | 1개월 전 | 291 | ||
| 199711 |
안졸리니졸리니
|
1개월 전 | 144 | |
| 199710 |
|
1개월 전 | 160 | |
| 199709 |
|
1개월 전 | 91 | |
| 199708 | 1개월 전 | 106 | ||
| 199707 | 1개월 전 | 240 | ||
| 199706 | 1개월 전 | 41 | ||
| 199705 | 1개월 전 | 29 | ||
| 199704 | 1개월 전 | 46 | ||
| 199703 | 2개월 전 | 57 | ||
| 199702 | 2개월 전 | 97 | ||
| 199701 | 2개월 전 | 111 | ||
| 199700 | 2개월 전 | 83 | ||
| 199699 | 2개월 전 | 88 | ||
| 199698 | 2개월 전 | 134 | ||
| 199697 | 2개월 전 | 99 | ||
| 199696 |
|
2개월 전 | 245 | |
| 199695 | 2개월 전 | 88 | ||
| 199694 | 2개월 전 | 117 | ||
| 199693 | 2개월 전 | 185 | ||
| 199692 | 2개월 전 | 195 | ||
| 199691 |
|
2개월 전 | 169 | |
| 199690 | 2개월 전 | 257 | ||
| 199689 | 2개월 전 | 160 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기