문서의 선택한 두 판 사이의 차이를 보여줍니다.
양쪽 이전 판 이전 판 다음 판 | 이전 판 | ||
wiki:javascript:jquery:jquery_note:jquery_events [2021/04/15 13:33] emblim98 |
wiki:javascript:jquery:jquery_note:jquery_events [2023/01/13 18:44] (현재) |
||
---|---|---|---|
줄 1: | 줄 1: | ||
======jQuery Event Methods====== | ======jQuery Event Methods====== | ||
- | <WRAP left notice | + | <WRAP left notice |
* description : jQuery Event Methods | * description : jQuery Event Methods | ||
* author | * author | ||
줄 28: | 줄 28: | ||
| mouseenter | | mouseenter | ||
| mouseleave | | mouseleave | ||
- | \\ | + | |
=====jQuery Syntax For Event Methods===== | =====jQuery Syntax For Event Methods===== | ||
%%jQuery%%에서, | %%jQuery%%에서, | ||
줄 45: | 줄 45: | ||
}); | }); | ||
</ | </ | ||
+ | \\ | ||
======Commonly Used jQuery Event Methods====== | ======Commonly Used jQuery Event Methods====== | ||
=====$(document).ready()===== | =====$(document).ready()===== | ||
줄 60: | 줄 60: | ||
====예제==== | ====예제==== | ||
<code jquery> | <code jquery> | ||
- | $(" | + | $(document).ready(function () { |
- | $(this).hide(); | + | |
- | }); | + | $(this).hide(); |
+ | }); | ||
+ | | ||
</ | </ | ||
줄 72: | 줄 74: | ||
====예제==== | ====예제==== | ||
<code jquery> | <code jquery> | ||
- | $(" | + | $(document).ready(function () { |
- | $(this).hide(); | + | |
- | }); | + | $(this).hide(); |
+ | }); | ||
+ | | ||
</ | </ | ||
줄 84: | 줄 88: | ||
====예제==== | ====예제==== | ||
<code jquery> | <code jquery> | ||
- | $("# | + | $(document).ready(function () { |
- | alert(" | + | |
- | }); | + | alert(" |
+ | }); | ||
+ | | ||
</ | </ | ||
줄 96: | 줄 102: | ||
====예제==== | ====예제==== | ||
<code jquery> | <code jquery> | ||
- | $(this).mouseleave(function() { | + | |
- | alert(" | + | $("# |
- | }); | + | alert(" |
+ | }); | ||
+ | | ||
</ | </ | ||
줄 108: | 줄 116: | ||
====예제==== | ====예제==== | ||
<code jquery> | <code jquery> | ||
- | $("# | + | $(document).ready(function () { |
- | alert(" | + | |
- | }); | + | alert(" |
+ | }); | ||
+ | | ||
</ | </ | ||
줄 120: | 줄 130: | ||
====예제==== | ====예제==== | ||
<code jquery> | <code jquery> | ||
- | $("# | + | $(document).ready(function () { |
- | alert(" | + | |
- | }); | + | alert(" |
+ | }); | ||
+ | | ||
</ | </ | ||
줄 132: | 줄 144: | ||
====예제==== | ====예제==== | ||
<code jquery> | <code jquery> | ||
- | $("# | + | $(document).ready(function () { |
- | alert(" | + | |
- | }, | + | alert(" |
- | function() { | + | }, |
- | alert(" | + | function () { |
- | }); | + | alert(" |
+ | }); | ||
+ | | ||
</ | </ | ||
줄 147: | 줄 161: | ||
====예제==== | ====예제==== | ||
<code jquery> | <code jquery> | ||
- | $(" | + | $(document).ready(function () { |
- | $(this).css(" | + | |
- | }); | + | $(this).css(" |
+ | }); | ||
+ | $(" | ||
+ | $(this).css(" | ||
+ | }); | ||
+ | | ||
</ | </ | ||
줄 159: | 줄 178: | ||
====예제==== | ====예제==== | ||
<code jquery> | <code jquery> | ||
- | $(" | + | $(" |
$(this).css(" | $(this).css(" | ||
}); | }); | ||
줄 171: | 줄 190: | ||
====예제==== | ====예제==== | ||
<code jquery> | <code jquery> | ||
- | $(" | + | $(document).ready(function () { |
- | $(this).hide(); | + | |
- | }); | + | $(this).hide(); |
+ | }); | ||
+ | | ||
</ | </ | ||
\\ | \\ | ||
줄 180: | 줄 201: | ||
====예제==== | ====예제==== | ||
<code jquery> | <code jquery> | ||
- | $(" | + | $(document).ready(function () { |
- | mouseenter: function() { | + | |
- | $(this).css(" | + | mouseenter: function () { |
- | }, | + | $(this).css(" |
- | mouseleave: function() { | + | }, |
- | $(this).css(" | + | mouseleave: function () { |
- | }, | + | $(this).css(" |
- | click: function() { | + | }, |
- | $(this).css(" | + | click: function () { |
- | } | + | $(this).css(" |
- | }); | + | } |
+ | }); | ||
+ | | ||
</ | </ | ||