COMING SOON 🚀

모바일 OS에서 자바스크립트 select() 구현하기 입니다.

· 10년 전 · 1288

<textarea id="idText">
Hello Apple!
Hello Android!
</textarea>

<script language="javascript" type="text/javascript">
var Mobile="";
var sUsrAgt=navigator.userAgent;

if((/iPhone/i.test(sUsrAgt)) || (/iPod/i.test(sUsrAgt))) Mobile="IP";
else if((/series60/i.test(sUsrAgt)) || (/symbian/i.test(sUsrAgt))) Mobile="SY";
else if(/iPad/i.test(sUsrAgt)) Mobile="IA";
else if(/android/i.test(sUsrAgt)) Mobile="AN";
else if(/windows ce/i.test(sUsrAgt)) Mobile="WM";
else if(/blackberry/i.test(sUsrAgt)) Mobile="BB";
else if(/palm/i.test(sUsrAgt)) Mobile="PM";
else if(/Kindle/i.test(sUsrAgt)) Mobile="KD";

var oTextArea=document.getElementById("idText");

function selectMobile() {
oTextArea.setSelectionRange(0, 9999);
}

function selectAll()
{
if (Mobile) {
oTextArea.focus();
setTimeout("selectMobile()",1234);
}
else {
oTextArea.select();
}
}

selectAll();

</script>

|
댓글을 작성하시려면 로그인이 필요합니다.

프로그램

+
제목 글쓴이 날짜 조회
10년 전 조회 1,232
10년 전 조회 1,195
10년 전 조회 1,208
10년 전 조회 1,225
10년 전 조회 1,282
10년 전 조회 1,198
10년 전 조회 1,429
10년 전 조회 1,584
10년 전 조회 1,486
10년 전 조회 1,237
10년 전 조회 1,244
10년 전 조회 1,195
10년 전 조회 1,192
10년 전 조회 1,309
10년 전 조회 1,241
10년 전 조회 1,179
10년 전 조회 1,239
10년 전 조회 1,589
10년 전 조회 2,049
10년 전 조회 1,627
10년 전 조회 1,448
10년 전 조회 1,409
10년 전 조회 1,260
10년 전 조회 1,247
10년 전 조회 1,268
10년 전 조회 1,230
10년 전 조회 1,236
10년 전 조회 1,267
10년 전 조회 1,427
10년 전 조회 1,337
10년 전 조회 2,058
10년 전 조회 1,594
10년 전 조회 1,341
10년 전 조회 1,428
10년 전 조회 1,686
10년 전 조회 1,356
10년 전 조회 1,538
10년 전 조회 1,377
10년 전 조회 1,484
10년 전 조회 1,326
10년 전 조회 1,299
10년 전 조회 1,290
10년 전 조회 1,321
10년 전 조회 1,329
10년 전 조회 1,358
10년 전 조회 1,381
10년 전 조회 1,360
10년 전 조회 1,515
10년 전 조회 1,503
10년 전 조회 1,289
10년 전 조회 1,588
10년 전 조회 1,946
10년 전 조회 1,378
10년 전 조회 1,646
10년 전 조회 1,604
10년 전 조회 1,454
10년 전 조회 1,411
10년 전 조회 1,371
10년 전 조회 1,491
10년 전 조회 1,235
10년 전 조회 1,305
10년 전 조회 1,531
10년 전 조회 1,355
10년 전 조회 1,347
10년 전 조회 1,309
10년 전 조회 1,331
10년 전 조회 1,319
10년 전 조회 1,323
10년 전 조회 1,343
10년 전 조회 1,282
10년 전 조회 1,459
10년 전 조회 1,286
10년 전 조회 1,289
10년 전 조회 1,376
10년 전 조회 2,116
10년 전 조회 1,345
10년 전 조회 1,338
10년 전 조회 1,430
10년 전 조회 1,332
10년 전 조회 1,504
10년 전 조회 1,415
10년 전 조회 1,347
10년 전 조회 1,343
10년 전 조회 1,388
10년 전 조회 1,371
10년 전 조회 1,282
10년 전 조회 1,249
10년 전 조회 1,212
10년 전 조회 1,253
10년 전 조회 1,636
10년 전 조회 1,289
10년 전 조회 1,398
10년 전 조회 1,350
10년 전 조회 1,578
10년 전 조회 1,368
10년 전 조회 1,319
10년 전 조회 1,326
10년 전 조회 1,360
10년 전 조회 1,478
10년 전 조회 1,417