'JavaScript > jQuery' 카테고리의 다른 글
| jQuery Carousel - modular (2) | 2012.11.27 |
|---|---|
| has(), is() (0) | 2012.07.22 |
| jQuery 플러그인과 그 메서드들을 만들기 위한 기본구조.. (0) | 2012.01.01 |
| jQuery 플러그인들 수집 (0) | 2011.12.28 |
| jQuery Template (0) | 2011.12.27 |
| jQuery() 함수 인자들 정리 (0) | 2011.11.07 |
| jQuery Carousel - modular (2) | 2012.11.27 |
|---|---|
| has(), is() (0) | 2012.07.22 |
| jQuery 플러그인과 그 메서드들을 만들기 위한 기본구조.. (0) | 2012.01.01 |
| jQuery 플러그인들 수집 (0) | 2011.12.28 |
| jQuery Template (0) | 2011.12.27 |
| jQuery() 함수 인자들 정리 (0) | 2011.11.07 |
http://www.gougouzian.fr/projects/jquery/moodular/
<ul id="demo">
<li>
<img src="img/photo01.jpg" />
</li>
<li>
<img src="img/photo02.jpg" />
</li>
<li>
<img src="img/photo03.jpg" />
</li>
<li>
<img src="img/photo04.jpg" />
</li>
<li>
<img src="img/photo05.jpg" />
</li>
<li>
<img src="img/photo06.jpg" />
</li>
</ul>
The CSS is :
#demo, #demo li { margin:0; padding:0; width:900px; height:495px; list-style:none; }
#demo { overflow: hidden; }
#demo li { float:left; }
The JavaScript is :
jQuery('#demo').moodular({
effects: 'left',
controls: '',
auto: true,
easing: '',
speed: 1000,
dispTimeout: 3000
});
| Mouse Wheel (0) | 2012.11.27 |
|---|---|
| has(), is() (0) | 2012.07.22 |
| jQuery 플러그인과 그 메서드들을 만들기 위한 기본구조.. (0) | 2012.01.01 |
| jQuery 플러그인들 수집 (0) | 2011.12.28 |
| jQuery Template (0) | 2011.12.27 |
| jQuery() 함수 인자들 정리 (0) | 2011.11.07 |
.has(selector)
자식요소로 selector를 가진 것들로 선택범위 축소
ex) $('.title').has($(this))
http://api.jquery.com/has/
.is(selector)
선택요소의 성질이 맞는지 boolean 리턴
ex) $('#container').is(':visible')
http://api.jquery.com/is/
| Mouse Wheel (0) | 2012.11.27 |
|---|---|
| jQuery Carousel - modular (2) | 2012.11.27 |
| jQuery 플러그인과 그 메서드들을 만들기 위한 기본구조.. (0) | 2012.01.01 |
| jQuery 플러그인들 수집 (0) | 2011.12.28 |
| jQuery Template (0) | 2011.12.27 |
| jQuery() 함수 인자들 정리 (0) | 2011.11.07 |
<div class="test" id="XX"></div>
<div class="test" id="YY"></div>
<script>
$.fn.plug = function(){
var o = this;
o.html("AA");
o.aa = function(){
alert(o===this); // true
o.each(function(i, k){
$(k).html(i+"th : "+k.id);
});
}
return o;
}
var x = $('.test').plug();
</script>
<input type="button" onclick="x.aa()">
| Mouse Wheel (0) | 2012.11.27 |
|---|---|
| jQuery Carousel - modular (2) | 2012.11.27 |
| has(), is() (0) | 2012.07.22 |
| jQuery 플러그인들 수집 (0) | 2011.12.28 |
| jQuery Template (0) | 2011.12.27 |
| jQuery() 함수 인자들 정리 (0) | 2011.11.07 |
| Mouse Wheel (0) | 2012.11.27 |
|---|---|
| jQuery Carousel - modular (2) | 2012.11.27 |
| has(), is() (0) | 2012.07.22 |
| jQuery 플러그인과 그 메서드들을 만들기 위한 기본구조.. (0) | 2012.01.01 |
| jQuery Template (0) | 2011.12.27 |
| jQuery() 함수 인자들 정리 (0) | 2011.11.07 |
<!DOCTYPE html>
<html>
<head>
<script src="http://code.jquery.com/jquery-latest.min.js"></script>
<script src="http://ajax.microsoft.com/ajax/jquery.templates/beta1/jquery.tmpl.min.js"></script>
</head>
<body>
<script id="movieTemplate" type="text/x-jquery-tmpl">
<li>
Title: ${Name} ${index}
{{each Languages}}
${$index + 1}: <em>${$value}. </em>
{{/each}}
</li>
</script>
<ul id="movieList"></ul>
<script>
var movies = [
{ Name: "Meet Joe Black", Languages: ["French"] },
{ Name: "The Mighty", Languages: [] },
{ Name: "City Hunter", Languages: ["Mandarin", "Cantonese"] }
];
/* Render the template with the movies data */
$( "#movieTemplate" ).tmpl( movies )
.appendTo( "#movieList" );
</script>
</body>
</html>
| Mouse Wheel (0) | 2012.11.27 |
|---|---|
| jQuery Carousel - modular (2) | 2012.11.27 |
| has(), is() (0) | 2012.07.22 |
| jQuery 플러그인과 그 메서드들을 만들기 위한 기본구조.. (0) | 2012.01.01 |
| jQuery 플러그인들 수집 (0) | 2011.12.28 |
| jQuery() 함수 인자들 정리 (0) | 2011.11.07 |
| Mouse Wheel (0) | 2012.11.27 |
|---|---|
| jQuery Carousel - modular (2) | 2012.11.27 |
| has(), is() (0) | 2012.07.22 |
| jQuery 플러그인과 그 메서드들을 만들기 위한 기본구조.. (0) | 2012.01.01 |
| jQuery 플러그인들 수집 (0) | 2011.12.28 |
| jQuery Template (0) | 2011.12.27 |