$('<img>', {
src: 'images/little.bear.png',
alt: 'Little Bear',
title:'I woof in your general direction',
click: function(){
alert($(this).attr('title'));
}
}).css({
cursor: 'pointer',
border: '1px solid black',
padding: '12px 12px 20px 12px',
backgroundColor: 'white'
}).appendTo('body');
'Web > JQuery' 카테고리의 다른 글
제이쿼리 버전 상관없이 최신버전만 사용하는 방법 (0) | 2017.07.24 |
---|---|
jQuery closest(), parents() 메소드의 차이 (0) | 2017.02.09 |
event.stopPropagation(), event.preventDefault () 이해하기 (0) | 2017.02.01 |
제이쿼리 슬라이드 화면 실습 (0) | 2016.07.07 |
제이쿼리 이런식으로도 사용 가능하다. 참고 (0) | 2016.06.17 |