Quantcast
Channel: Infomation Technology » jquery
Viewing all articles
Browse latest Browse all 10

load() 이벤트 처리기 메서드

$
0
0

“load” 자바스크립트 이벤트에 이벤트 처리기 바인딩.

사용방법은 다음과 같다.

 

ex1)

$(window).load(function () {

// run code

});

 

ex2)

$(‘img.userIcon’).load(function(){

if($(this).height() > 100) {

$(this).addClass(‘bigImg’);

}

});


Viewing all articles
Browse latest Browse all 10