일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
- Eclipse
- pwa
- Next.js
- Java
- nodejs
- FCM
- docker
- yona
- PM2
- jquery
- MSsql
- config
- popup
- mysql
- Tomcat
- node.js
- javascript
- SpringBoot
- centos7
- MariaDB
- jenkins
- spring3
- Push
- Maven
- mybatis
- security
- git
- rocky9
- ajax
- NextJS
- Today
- Total
목록javascript (50)
종이 한장 차이...
특정 html에 click 이벤트를 걸고 해당 요소를 클릭 하면 소요내의 content를 dailog 창에 표시 한다. tr을 동적으로 추가 하는 부분은 생략... 참고: 아래 소스의 경우 html로딩이 완료 되고난후 특정 구역에 html을 add하는 경우에도 새로add한 html소요에도 클릭 이벤트가 적용 된다. $(document).ready(function(){ }); //ready 밖에 function 영역에 작성 해야함. var test = $('body'); test.on("click",".js_sordMemo",function (e) { $('.popupLayer').hide(); //console.log($(this).children('input').val()); var sWidth = w..
input에 타이핑할 때마다 들어온 문자열이 유효하지 않을 경우 안내 문구 UI를 .show(); 하다. 규칙에 맞는 문자열이 완성될 경우 안내문구 UI를 .hide(); 한다. /*전화번호 수동 입력시 자동완성 기능. js_tel_in_format클래스는 모두 적용됨.*/ $(document).on("keyup", ".js_tel_in_format", function(idx,data) { $(this).val( $(this).val().replace(/[^0-9]/g, "").replace(/(^02|^0505|^1[0-9]{3}|^0[0-9]{2})([0-9]+)?([0-9]{4})$/,"$1-$2-$3").replace("--", "-") ); //휴대폰 휴효성 검사 if($(this).attr("..
팝업 링크를 호출 하는 순간(popUpBtn()함수가 호출 되면) form을 구성하여 window.open()에 매핑 하여 처리를 한다. function popUpBtn(){ window.open("", "tempInfoView", "directories=no,titlebar=no,toolbar=no,status=no,menubar=no, location=no,width=850, height=700, scrollbars=yes"); var tempInfoForm = document.createElement('form'); tempInfoForm.name= "tempInfoView"; tempInfoForm.action = "/info/tempInfo"; tempInfoForm.method= "POST";..
# 고유ID 값을 checkbox의 value에 저장 후 해당 value가 담긴 array[]를 서버로 전송하여 일괄 삭제 또는 일괄저장 등을 할 경우 참조. # html 소스 #javascript 소스
1번 2번 3번 4번 5번 6번 위와 같은 li리스트가 있을 경우 아래와 같이 li의 attribute를 참조하여 class가 "top" 인 모든 li를 each로 돌면서 li의 data-top이 "2" 인 것의 data-name값을 콘솔에 찍는다. $('li[class="top"]').each(function(index,item){ if(item.getAttribute("data-top") == '2'){ console.log(item.getAttribute("data-name").trim()); } }); 위의 결과로 "2번"이 출력 된다. //li선택자를 여러개 줄경우 $('li[class="top"][data-top="1"][data-name="2번"]') //li의 가장 첫번째의 span에 cl..
버튼 클릭시 특정 기능 동작전에 IE인지 Chrom인지 구분해서 처리 하기. $('#printBtn').click(function (){ // if( navigator.userAgent.indexOf("MSIE") > 0 ){ // window.frames["iframe"].focus(); // window.frames["iframe"].print(); // //preview_print(); // } else if( navigator.userAgent.indexOf("Chrome") > 0){ window.frames["iframe"].focus(); window.frames["iframe"].print(); // } });